'Connection refused' usually means you have established a connection to the machine, but its not happy with your attempt to log in.
I suggest you run ansible with -vvvvv which will give you a bit more debug information and check that the user you are connecting with is the one you expect. Also worth checking the event log on the windows box to see if there's any information about why the connection was refused. Double check you've run all the setup instructions (including running the configure for remoting script on the remote windows machine). If you are still stuck, connect to the windows box and run the following as administrator winrm get winrm/config Also if the machine is running S2008R2 make sure the WMF 3.0 hotfix http://support.microsoft.com/kb/2842230 has been installed - its documented in the blue Notes box at the bottom of this section of the windows documentation page: http://docs.ansible.com/ansible/intro_windows.html#windows-system-prep Please let us know how you get on. Jon On Monday, July 3, 2017 at 1:51:51 PM UTC+1, Chris wrote: > > I'm trying to use Ansible for a Windows host. I followed the > instructions, but I'm getting an error when I try to run anything simple: > ansible inventory -m setup or ansible inventory -m wing_ping > > Host IP| UNREACHABLE! => { > "changed": false, > "msg": "ssl: HTTPSConnectionPool(host='Host IP', port=5986): Max > retries exceeded with url: /wsman (Caused by > NewConnectionError('<urllib3.connection.VerifiedHTTPSConnection object at > 0xbc8550>: Failed to establish a new connection: [Errno 111] Connection > refused',))", > "unreachable": true > } > > This is just a workgroup so local accounts. Any ideas? Thanks > -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/40581a6a-32cf-4649-96d2-44a68af5d377%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
