The other day I ran in to an annoying WinRM problem on a node installed with Windows Hyper-V Server 2008 R2. I wanted to open Server Manager and connect to the specific node.

Although WinRM was enabled via sconfig, I couldn’t connect to it use the Server Manger from a full installation to do some basic troubleshooting.

image
 

Remote Management is enabled according to sconfig. But is it completely!

image

 

Check #1. The standard command “winrm qc” to configure WinRM gave the following result

image

So everything should work. NOT!

Check #2. When doing a “winrm id –r:<servername>” I got the result below.

image
 

WSManFault
 
Message = The WinRM client cannot complete the operation within the time specified. Check if the machine name is valid and is reachable over the network and
 
firewall exception for Windows Remote Management service is enabled.
 
Error number: -2144108250 0×80338126
 
The WinRM client cannot complete the operation within the time specified. Check
 
if the machine name is valid and is reachable over the network and firewall exception for Windows Remote Management service is enabled.
 
That’s not a good sign.

Check #3. When doing a “winrm e winrm/config/listener” I got the result below.

image
 

That’s funny….it is listening on port 80…..why?

Check #4.When checking the firewall I saw that not all the rules needed where enabled.

image
 

But according to sconfig everything should be up and running. This is backed by the fact that “winrm qc” is stating that everything is configured and is up and running as it should be.

O wait, the firewall has port 5985 open, and WinRM has a listener configured on port 80. Not gonna happen I think!

Solution:

The way to resolve this has many parts and is very simple . Just delete all listeners and let them be recreated by running the quick configure command.

  1. Quickly delete the WS-Man listener: winrm invoke Restore winrm/Config @{}
  2. Quick configure WinRM and answer Y: winrm qc
  3. Check is no listeners are present anymore: winrm e winrm/config/listener

image

A simple test to find out if WinRM is working as it should is “winrm id –r:<servername>

image

And now the Server Manager is also connecting to the remote server.

image

All done! The Server Manager is now able to connect remotely using WinRM. Possible that SCVMM related issues will disappear to!

GO! And start fixing those WinRM issues!