1.查看是否开启3389 (0表示开启,1表示关闭)
REG QUERY "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Terminal Server" /v fDenyTSConnections
- 查看开启的端口 (16进制的需换算成10进制)
reg query "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Terminal Server\WinStations\RDP-Tcp" /v portnumber
- 开启3389命令
win08使用一下三条命令:
1.
wmic /namespace:\\root\cimv2\terminalservices path win32_terminalservicesetting where (__CLASS != "") call setallowtsconnections 1
2.
wmic /namespace:\\root\cimv2\terminalservices path win32_tsgeneralsetting where (TerminalName ='RDP-Tcp') call setuserauthenticationrequired 1
3.
reg add "HKLM\SYSTEM\CurrentControlSet\Control\Terminal Server" /v fSingleSessionPerUser /t REG_DWORD /d 0 /f
别的版本系统:
win2012通用;win7执行前两条即可。权限需要run as administrator。
win03 winxp 一条命令即可:
wmic path win32_terminalservicesetting where (__CLASS != "") call setallowtsconnections 1








网友评论