I successfully enabled PSRemoting on my 2008 R2 server. I can do remote pssession from the same network using the hostname as the target.
I fail when I try to use the IP address as a target from any computer (inside the network or from another network (for example, via VPN)). I want to be able to use a remote connection through my VPN connection, where I need to use an IP address because the host name cannot be resolved.
I donβt want to add names to my host file because there are several other servers on our clients that have the same DNS name, and I donβt want to delete and insert name-ip-address-connection again and again.
I hope someone tells me how to resolve the psremoting-target call over IP.
Change To be more specific, I want to be able to run this:
Enter-PSSession -Computername 192.168.123.123 -credentials $cred
But I can execute this command only if I pass the host name to " -Computername "
Edit2 :
I get the following errormessage when I try to login using ip instead of the host name (from the internal network):
Enter-PSSession : Connecting to remote server failed with the following error message : The WinRM client cannot process the request. Default authentication may be used with an IP address under the following conditions: the transport is HT TPS or the destination is in the TrustedHosts list, and explicit credentials are provided. Use winrm.cmd to configure T rustedHosts. Note that computers in the TrustedHosts list might not be authenticated. For more information on how to se t TrustedHosts run the following command: winrm help config. For more information, see the about_Remote_Troubleshooting Help topic.
Edit3:
I know about setting up WSMan trusted hosts, but that doesn't seem to be the problem. It is already set to "*" (I did it right after enabling remote access), but I still canβt connect to this server using ip as target-computername, but I can connect using the host name as the name -target-computername, It seems that there is something like a binding in IIS that does not allow the listener to listen for requests that target the ip number instead of the host name. But IIS is not installed. I do not know where to look for such a setting.
Update 2011-07-12:
Well, I think that trustedhosts-setting is not a problem, because I can connect from our DC through the host name, but not if I use the destination ip address for param computer.
I think the problem should be a listener. The listener may not accept requests destined for ip target instead of hostname. But I do not know how to change this.
powershell remoting powershell-remoting
wullxz Jul 05 '11 at 18:50 2011-07-05 18:50
source share