How to launch a program automatically when logging into Remote Desktop server 2019
[WINDOWS SERVER 2019] Start a program with the remote desktopGoodmorning everyone, Show Comment Comment Show 0 Comment 5 |1600 characters needed characters left characters exceeded
▼
Attachments: Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total. JennyYan-MSFT answered • Nov 17, '20 | reteinformatica commented • Nov 19, '20 Hi, 2.Per my knowledge, RD Session Host Role Service is required to use the start a program on connection feature. Did you installed RDSH role for the server? 3.The most widely used method to disable Remote Desktop Access but allow RemoteAPPs is the one shared in below thread: User Configuration > Policies > Administrative Templates > Windows Components > Remote Desktop Services > Remote Desktop Session Host > Remote Session Environment > Start a program on connection https://social.technet.microsoft.com/Forums/lync/en-US/5d17f131-c6d1-49dd-b0b7-83c03c3fedbb/how-to-disable-remote-desktop-access-but-allow-remoteapps-to-run?forum=winserverTS Hope this helps and please help to accept as Answer if the response is useful. Thanks, Comment Comment · Show 2 Comment 5 |1600 characters needed characters left characters exceeded
▼
Attachments: Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total. JennyYan-MSFT · Nov 18, 2020 at 01:31 AM Hi, Please feel free to let us know if any more questions and please help to mark useful response as Answer to end the thread. Best Regards, 0 Votes 0 · reteinformatica JennyYan-MSFT · Nov 19, 2020 at 08:15 PM Hello, Jenny, 0 Votes 0 · reteinformatica answered • Nov 19, '20 | JennyYan-MSFT commented • Nov 20, '20 Hello, yes I installed Remote Desktop Host services. Comment Comment · Show 1 Comment 5 |1600 characters needed characters left characters exceeded
▼
Attachments: Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total. JennyYan-MSFT · Nov 20, 2020 at 07:48 AM Hi, Moreover RDS environment could be configured in domain or in workgroup with relevant type of RDS CAL. Thanks, 0 Votes 0 · reteinformatica answered • Nov 20, '20 | reteinformatica edited • Nov 20, '20 Hi Jenny, I think I don't know and understand what goes into "SessionHost". I tried to put server hostname (Server2019) but I receive another error: Cmdlet New-RDSessionCollection in position 1 of the command pipeline Specify values for the following parameters: CollectionName: test SessionHost[0]: server2019.workgroup SessionHost[1]: New-RDSessionCollection : There is no Remote Desktop Services deployment on Server2019. This operation it can only be run after you have created a distribution. For information on creating a distribution, execute the command "Get-Help New-RDVirtualDesktopDeployment" o "Get-Help New-RDSessionDeployment". In line:1 car:1 + New-RDSessionCollection -PersonalUnmanaged + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + CategoryInfo : NotSpecified: (:) [Write-Error], WriteErrorException + FullyQualifiedErrorId : Microsoft.PowerShell.Commands.WriteErrorException,New-RDSessionCollectionThen I tried how it is written, others errors: PS C:\Users\Administrator> New-RDVirtualDesktopDeployment Cmdlet New-RDVirtualDesktopDeployment in position 1 of the command pipeline Specify values for the following parameters: ConnectionBroker: Server2019 VirtualizationHost[0]: server2019.workgroup VirtualizationHost[1]: New-RDVirtualDesktopDeployment : Failed to validate "RD Connection Broker" parameter. Server2019 No valid fully qualified domain name (FQDN) specified for the server. In riga:1 car:1 + New-RDVirtualDesktopDeployment + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + CategoryInfo : NotSpecified: (:) [Write-Error], WriteErrorException + FullyQualifiedErrorId : Microsoft.PowerShell.Commands.WriteErrorException,New-RDVirtualDesktopDeployment PS C:\Users\Administrator> New-RDVirtualDesktopDeployment Cmdlet New-RDVirtualDesktopDeployment in position 1 of the command pipeline Specify values for the following parameters:ConnectionBroker: Server2019 VirtualizationHost[0]: server2019 VirtualizationHost[1]: New-RDVirtualDesktopDeployment : Failed to validate "RD Connection Broker" parameter. Server2019 No valid fully qualified domain name (FQDN) specified for the server. In line:1 car:1 + New-RDVirtualDesktopDeployment + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + CategoryInfo : NotSpecified: (:) [Write-Error], WriteErrorException + FullyQualifiedErrorId : Microsoft.PowerShell.Commands.WriteErrorException,New-RDVirtualDesktopDeployment Comment Comment Show 0 Comment 5 |1600 characters needed characters left characters exceeded
▼
Attachments: Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total. JennyYan-MSFT answered • Nov 23, '20 Hi, But if you are new to remote desktop service, it is suggested to deploy RDS via GUI with following screenshots and get better understanding for each roles related to RDS. For the information you posted, it seemed that you did not specify the FQDN of collection or server of RDCB and RDSH. Moreover, command"New-RDVirtualDesktopDeployment" is used to install the role services of VDI instead of RD session host. Last but not least, here are step by step guidance on how to deploy RDS with powershell command: Hope this helps and please help to accept as Answer if the response is useful. Thanks, Comment Comment Show 0 Comment 5 |1600 characters needed characters left characters exceeded
▼
Attachments: Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total. Specify a Program to Start Automatically When a User Logs On Does Not Work in 2016 Server
Archived Forums >Remote Desktop Services (Terminal Services)
Answers
All replies
15 Replies
· · ·
Pure Capsaicin OP
Neally
This person is a verified professional.
Verify your account
to enable IT peers to see that you are a professional.
Not sure if you can do that, you are looking for some kind of 'kiosk' mode? Have you looked into RDweb? So you can just give them access to the aplication, which would basically bypass all that lock down stuff? 1
· · ·
Datil OP
britv8 Sep 8, 2017 at 00:38 UTC
Published applications would be what you would use. What OS are we talking about?2012 and higher? 1
· · ·
Datil OP
gb5102 Sep 8, 2017 at 01:31 UTC
First thing that comes to mind is the setting in the RD client itself: 0
· · ·
Datil OP
gb5102 Sep 8, 2017 at 01:41 UTC
This can also be done via GPO(it is also under User Configuration):
Text Computer Configuration\Policies\Administrative Templates\Windows Components\Remote Desktop Services\Remote Desktop Session Host\Remote Session Environment - "Start a program on connection"or Registry(it is also under HKCU):
Text HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services - Values: InitialProgram, WorkDirectory0
· · ·
Jalapeno OP
ziceman Sep 8, 2017 at 03:34 UTC
In this case, the device accessing the terminal server is a thin client. So I need to create the configuration on the back and, right? 0
· · ·
Jalapeno OP
ziceman Sep 8, 2017 at 03:34 UTC
in this case, the machine accessing the terminal server is a thin device, so I have to create the config on the backend, right? 0
· · ·
Jalapeno OP
ziceman Sep 8, 2017 at 03:36 UTC
sorry for double reply. doing this from my phone. not trying to be annoying... 1
· · ·
Mace OP
adrian_ych
This person is a verified professional.
Verify your account
to enable IT peers to see that you are a professional.
Active Directory & GPO expert
40 Best Answers 227 Helpful Votes
Are you trying TS application publishing ? So that users only can use applications on the Terminal server ? Else users can still close the application and run other stuff on the terminal server... https://technet.microsoft.com/en-us/library/cc730673(v=ws.10).aspx 0
· · ·
Pure Capsaicin OP
dbeato
This person is a verified professional.
Verify your account
to enable IT peers to see that you are a professional.
Do they have a program in the startup folder for the users that is working ? 0
· · ·
Jalapeno OP
ziceman Sep 8, 2017 at 15:15 UTC
OK. I believe I have found the way this has been set up in the past, but it is not working when a new user configuration is created. In Remote Desktop Session Host Configuration in the Connection properties, we have this: .... deferring to the user profile or client. In the existing AD user configuration we have settings in RD Services Profile tab that maps drives, and settings in the Environment tab that specifies a startup program. The current users are pointed at the correct vertical application path, and it appears to work just fine. I tried to duplicate this setup, but the program does not launch. Subsequently, I just stuck in the settings for Notepad. Still nothing. Is there something else that needs to be set / enabled on this? 0
· · ·
Jalapeno OP
ziceman Sep 8, 2017 at 15:20 UTC
The Start In field is actually set to: C:\users\gmt Also, I can get this to work by sticking the a shortcut to the app in the Startup folder for now, but this is ugly kludge. Just want to get the standard setup to function. 0
· · ·
Jalapeno OP
ziceman Sep 9, 2017 at 16:08 UTC
Just bumping this one. Still looking for an answer as to the Start Program at Logon is broken. Any more ideas? 0
· · ·
Jalapeno OP
ziceman Sep 11, 2017 at 14:09 UTC
bump, bump... ? 0
· · ·
Pure Capsaicin OP
dbeato
This person is a verified professional.
Verify your account
to enable IT peers to see that you are a professional.
I would check the permissions to the folders and check the that they can access the roaming profile. 0
· · ·
Jalapeno OP
Best Answer
ziceman Sep 12, 2017 at 18:35 UTC
OK. This has been solved. It turned out to be a GPO setting, which is very strange. This is because no one had been in there for months, so nothing should have been different. My next concern is making sure that server has not been compromised in some way. I wanted to check to see the last time the GPO was edited, but that date was updated the moment we went into it. Is there an audit trail for this? Anyway, gb5102 was close to the right track. The setting was actually Users\Policies\Administrative Templates\Windows Components\Remote Desktop Services\Remote Desktop Session Host\Remote Session Environment - "always show desktop on connection". Having this enabled completely blew away any directive to start up an application. No idea how it got set, and my concern is that this might signal malicious behavior. Needless to say, I have instituted a complete malware detection and remediation protocol on the server and also ratcheting up scans on all the other machines. One more thing I wanted to mention. Since this was a somewhat critical problem, I needed to get the situation resolved no later than end-of-day Monday. I decided to try the "LIVE" support feature of EE to see if I could get another set of eyeballs to look things over with me in real-time. I was happy to pay few $ to see if readily available assistance could save the day..., and it did. Does Spiceworks offer a similar service? If not, is it being considered? 0
This topic has been locked by an administrator and is no longer open for commenting. To continue this discussion, please ask a new question. Before you beginComplete these steps as they apply to your remote application configuration:
Note: For instructions on any of these remote desktop operations, see the documentation for your remote desktop server. In Enterprise Application Access (EAA), you can create a remote desktop application and configure the RDP application with settings that define how end users interact with the remote application environment. After you deploy a remote desktop application, end users can access the deployed application with the specified external hostname. |