I am configuring ansible (CentOS 6.7) to connnect to windows machine using http, winRM and kerberos
From the /etc/ansible/host
file
[training]
machinename:5985
I have set host specific yaml file
ansible_winrm_scheme: http
ansible_port: 5985
ansible_connection: winrm
Then, following command
ansible machinename -m win_ping -vvvv
errors with following
<machinename > ESTABLISH WINRM CONNECTION FOR USER: jnambood on PORT 5985 TO machinename
<machinename > WINRM CONNECT: transport=plaintext endpoint=http://machinename :5985/wsman
<machinename > WINRM CONNECTION ERROR: 401 Unauthorized.
<machinename > WINRM CONNECT: transport=plaintext endpoint=https://machinename :5985/wsman
<machinename > WINRM CONNECTION ERROR: 500 WinRMTransport. [Errno 1] _ssl.c:492: error:140770FC:SSL routines:SSL23_GET_SERVER_HELLO:unknown protocol
machinename | FAILED => 500 WinRMTransport. [Errno 1] _ssl.c:492: error:140770FC:SSL routines:SSL23_GET_SERVER_HELLO:unknown protocol
Ansible tried to http, got 401 error. How can I fix it?
Best Answer