Then yesterday's scene, although the default console for Windows Server Core is set to PowerShell, Remote Desktop is enabled, but for the core version of the server, Remote Desktop is the same as chicken, so I want to enable PowerShell remote access, Run with administrator rights on the server:
When attempting to establish a remote connection, prompt access is denied, which may be a firewall problem: I need to add PowerShell remote firewall rules using PowerShell:
New-netfirewallrule-name powershell-remote-tcp-direction inbound-displayname ' PowerShell remote connection tcp '-localport 5985-5996-protocol ' TCP '
new-netfirewallrule-name powershell-remote-udp-direction inbound-displayname ' PowerShell remote connection UDP '-localport 5985-5996-protocol ' UDP '
Try to establish the connection again:
ps> enter-pssession-computername 192.168.1.15-credential Administrator
[192.168.1.15]: PS C:\Users\ administrator\documents> hostname
AD-2012