Enable RDP for multiple sessions – command line option

rdpwindows-server-2012-r2

I'm already familiar with how to enable multiple RDP sessions for Server 2012 via the group policy editor. (https://support.managed.com/kb/a1816/how-to-enable-disable-multiple-rdp-sessions-in-windows-2012.aspx)

I was wondering if there was way I can somehow streamline this operation from a command line. I'm trying to streamline my deployments and this would speed up the process without taking the time to open up group policy editor and make the changes.

Best Answer

REG DELETE "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v fSingleSessionPerUser /f
REG DELETE "HKLM\SYSTEM\CurrentControlSet\Control\Terminal Server" /v fSingleSessionPerUser /f

This would also work:

REG ADD "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v fSingleSessionPerUser /t REG_DWORD /d 0 /f
REG ADD "HKLM\SYSTEM\CurrentControlSet\Control\Terminal Server" /v fSingleSessionPerUser /t REG_DWORD /d 0 /f