RDS 2019 issues related with to much services

%3CLINGO-SUB%20id%3D%22lingo-sub-1761435%22%20slang%3D%22en-US%22%3ERDS%202019%20issues%20related%20with%20to%20much%20services%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1761435%22%20slang%3D%22en-US%22%3E%3CP%3EHello%20All%2C%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EI%20have%20installed%20new%20RDS%20server%20on%20latest%202019%20standard%20server.%20This%20is%20standalone%20RDS%20server.%20Server%20is%20used%20by%20more%20than%20100%20people%20and%20has%20enough%20resources%20and%20licenses%20etc...%20Users%20can%20connect%20to%20one%20RDS%20web%20app%20published%20on%20the%20server%20without%20any%20problems.%20Everything%20looks%20fine%20till%20time%20when%20i%20want%20to%20check%20few%20things%20on%20the%20server.%3C%2FP%3E%3CP%3EI%20can't%20open%20services%20mmc%2C%20because%20i'm%20receiving%20error%20message%3A%20%22Error%201783%3A%20The%20stub%20received%20bad%20data%22%3A%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%221.JPG%22%20style%3D%22width%3A%20400px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F225185iD59BA56B5F1658FE%2Fimage-size%2Fmedium%3Fv%3D1.0%26amp%3Bpx%3D400%22%20title%3D%221.JPG%22%20alt%3D%221.JPG%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3CP%3ESame%20from%20powershell.%20Result%20of%20Get-Service%20is%20empty.%3C%2FP%3E%3CP%3ESolution%20is%20here%3A%3C%2FP%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Ftroubleshoot%2Fwindows-server%2Fsystem-management-components%2Ferror-1783-services-msc%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Ftroubleshoot%2Fwindows-server%2Fsystem-management-components%2Ferror-1783-services-msc%3C%2FA%3E%3C%2FP%3E%3CP%3ECompletely%20not%20acceptable%20for%20me%2C%20but%20i%20think%20above%20issue%20is%20correlated%20with%3A%20%22Per-user%20services%20in%20Windows%2010%20and%20Windows%20Server%22%3A%3C%2FP%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fwindows%2Fapplication-management%2Fper-user-services-in-windows%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fwindows%2Fapplication-management%2Fper-user-services-in-windows%3C%2FA%3E%3C%2FP%3E%3CP%3ESo%20if%20one%20user%20can%20create%20few%20services%2C%20how%20much%20services%20will%20be%20if%20on%20server%20will%20be%20more%20than%20100.%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EI%20can't%20open%20also%20Remote%20Desktop%20Services%20Overview%20from%20server%20manager%3A%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%222.JPG%22%20style%3D%22width%3A%20400px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F225187iE02C5FA070AE0F10%2Fimage-size%2Fmedium%3Fv%3D1.0%26amp%3Bpx%3D400%22%20title%3D%222.JPG%22%20alt%3D%222.JPG%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3ENext%20issue%20is%20related%20with%20monitoring%20system%20which%20can't%20get%20some%20data%20from%20this%20server.%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EEverything%20is%20comming%20back%20to%20normal%20if%20server%20is%20not%20used%20but%20to%20much%20of%20people%20at%20the%20evening%20for%20example%2C%20because%20when%20RDS%20session%20is%20disconnected%20then%20per%20user%20services%20also%20are%20removed.%20Then%20everything%20described%20above%20is%20working%20correctly.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3ESo%20my%20question%20is%20what%20is%20the%20solution%20for%20this%20case%2C%20because%20i%20as%20administrator%20can't%20provide%20good%20quality%20of%20the%20RDS%20service%2C%20because%20i%20don't%20see%20many%20things%20described%20above.%20Probably%20is%20much%20more.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-1761435%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EWindows%20Server%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1767961%22%20slang%3D%22en-US%22%3ERe%3A%20RDS%202019%20issues%20related%20with%20to%20much%20services%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1767961%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F825358%22%20target%3D%22_blank%22%3E%40KrzysztofSek%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3CP%3EI%20have%20this%20problem%20too.%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CBLOCKQUOTE%3E%3CP%3ESolution%20is%20here%3A%3C%2FP%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Ftroubleshoot%2Fwindows-server%2Fsystem-management-components%2Ferror-1783-services-msc%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Ftroubleshoot%2Fwindows-server%2Fsystem-management-components%2Ferror-1783-services-msc%3C%2FA%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CHR%20%2F%3E%3C%2FBLOCKQUOTE%3E%3CP%3EThat%20solution%20doesn't%20help.%20I%20think%20you%20are%20right%20about%20per-user%20services%3A%20it%20is%20still%20possible%20to%20monitor%20services%20by%20%22sc%20query%22%20or%20windows%20admin%20center%20and%20in%20my%20case%20it%20is%20over%20300%20services%20created%20when%20user%20logs%20in.%20Something%20like%20CDPUserSvc_*****.%26nbsp%3B%3C%2FP%3E%3CP%3EMaybe%20this%20can%20help%20for%20a%20very%20temporary%20solution%3F%26nbsp%3B%3C%2FP%3E%3CPRE%20class%3D%22lia-code-sample%20language-applescript%22%3E%3CCODE%3E%40echo%20off%0A%0Agoto%20main%0A%0A%3Aclsvc%0A%0AFOR%20%2FF%20%22tokens%3D1%2C2%20delims%3D%20%22%20%25%25A%20IN%20('SC%20QUERY%20state%5E%3D%20all%20%5E%7C%20find%20%22%25SN_STARTS_WITH%25%22')%20DO%20(%40echo%20%25%25B%20%26amp%3B%26amp%3B%20net%20stop%20%25%25B%20%26amp%3B%26amp%3B%20SC%20delete%20%25%25B)%0AEXIT%20%2FB%0A%0A%3Amain%0ASET%20SN_STARTS_WITH%3DWpnUserService_%0Acall%20%3Aclsvc%0ASET%20SN_STARTS_WITH%3DDevicePickerUserSvc_%0Acall%20%3Aclsvc%0ASET%20SN_STARTS_WITH%3DDevicesFlowUserSvc_%0Acall%20%3Aclsvc%0ASET%20SN_STARTS_WITH%3DConsentUxUserSvc_%0Acall%20%3Aclsvc%0ASET%20SN_STARTS_WITH%3DPimIndexMaintenanceSvc_%0Acall%20%3Aclsvc%0ASET%20SN_STARTS_WITH%3DCDPUserSvc_%0Acall%20%3Aclsvc%3C%2FCODE%3E%3C%2FPRE%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E
Highlighted
New Contributor

Hello All,

 

I have installed new RDS server on latest 2019 standard server. This is standalone RDS server. Server is used by more than 100 people and has enough resources and licenses etc... Users can connect to one RDS web app published on the server without any problems. Everything looks fine till time when i want to check few things on the server.

I can't open services mmc, because i'm receiving error message: "Error 1783: The stub received bad data":

1.JPG

Same from powershell. Result of Get-Service is empty.

Solution is here:

https://docs.microsoft.com/en-us/troubleshoot/windows-server/system-management-components/error-1783...

Completely not acceptable for me, but i think above issue is correlated with: "Per-user services in Windows 10 and Windows Server":

https://docs.microsoft.com/en-us/windows/application-management/per-user-services-in-windows

So if one user can create few services, how much services will be if on server will be more than 100. 

 

I can't open also Remote Desktop Services Overview from server manager:

2.JPG

 

Next issue is related with monitoring system which can't get some data from this server. 

 

Everything is comming back to normal if server is not used but to much of people at the evening for example, because when RDS session is disconnected then per user services also are removed. Then everything described above is working correctly.

 

So my question is what is the solution for this case, because i as administrator can't provide good quality of the RDS service, because i don't see many things described above. Probably is much more.

 

 

 

 

1 Reply
Highlighted

@KrzysztofSek 

I have this problem too. 

 

Solution is here:

https://docs.microsoft.com/en-us/troubleshoot/windows-server/system-management-components/error-1783...

 


That solution doesn't help. I think you are right about per-user services: it is still possible to monitor services by "sc query" or windows admin center and in my case it is over 300 services created when user logs in. Something like CDPUserSvc_*****. 

Maybe this can help for a very temporary solution? 

@echo off

goto main

:clsvc

FOR /F "tokens=1,2 delims= " %%A IN ('SC QUERY state^= all ^| find "%SN_STARTS_WITH%"') DO (@echo %%B && net stop %%B && SC delete %%B)
EXIT /B

:main
SET SN_STARTS_WITH=WpnUserService_
call :clsvc
SET SN_STARTS_WITH=DevicePickerUserSvc_
call :clsvc
SET SN_STARTS_WITH=DevicesFlowUserSvc_
call :clsvc
SET SN_STARTS_WITH=ConsentUxUserSvc_
call :clsvc
SET SN_STARTS_WITH=PimIndexMaintenanceSvc_
call :clsvc
SET SN_STARTS_WITH=CDPUserSvc_
call :clsvc