A: I recently needed to enable Remote Desktop Services (RDS) on a remote server. I used the process below to perform this remotely.
- Download PsExec from the Windows Sysinternals page at Microsoft's website and install it.
- Run the command below, changing the machine name for your remote machine. This sets the registry value, which enables and disables RDS connections:
psexec \\remotemachine reg add "hklm\system\currentcontrolset\control\terminal server" /f /v fDenyTSConnections /t REG_DWORD /d 0Now enable the firewall exceptions:
psexec \\ remotemachine netsh firewall set service remotedesktop enable
You should now be able to remotely connect to the remote machine.
Read FAQs about Windows, virtualization, systems management, and more at John Savill's FAQs for Windows.