winrm.py tries SSL handshake on WinRM HTTP port

227 views
Skip to first unread message

grobs

unread,
Apr 29, 2015, 11:40:55 AM4/29/15
to ansible...@googlegroups.com
Hi,

I' trying to run a simple test on a remote windows host.
I read http://docs.ansible.com/intro_windows.html and saw that Michael recommends to install pywinrm like this:

In my case, I don't have any possibility to run pip and hit github due to network security rules so I did it like this (on Debian 8 - Jessie):
  1. aptitude install python-isodate python-xmltodict python-pytest python-pytest-cov pep8
  2. # Downloaded http://github.com/diyan/pywinrm/archive/master.zip#egg=pywinrm and put it on my Ansible server
  3. unzip pywinrm-master.zip
  4. cd pywinrm-master/
  5. python setup.py install

All went well and I have this directory installed /usr/local/lib/python2.7/dist-packages/winrm/

After having modified file /usr/lib/python2.7/dist-packages/ansible/runner/connection_plugins/winrm.py as expected in https://github.com/ansible/ansible/issues/8720 , my problem is that when I run the ping test, this is what I get:

ansible windows_hosts -m win_ping
WINSRV-01 | FAILED => 500 WinRMTransport. [SSL: UNKNOWN_PROTOCOL] unknown protocol (_ssl.c:581)

Any idea?

I'm running ansible 1.7.2 (Debian package: ansible-1.7.2+dfsg-2 on Debian Jessie).

Tom

J Hawkesworth

unread,
May 1, 2015, 7:36:05 PM5/1/15
to ansible...@googlegroups.com
Can you run with -vvvvv - we might see the whole of the error?

Also can you share your group_vars for windows_hosts ?

My guess is you are missing a python dependency.

As an aside you might be able to install a more recent ansible from releases.ansible.com if you can work with the tar.gz

Jon
Reply all
Reply to author
Forward
0 new messages