Hello All,
I am trying to win_ping windows server from ansible but it is failing with error that specified credntials are rejected.
I have cross verified multiple times that group_vars,inventory,hosts etc files are all correctly updated with abosolutely correct password (I am able to RDP login to the server using these creds) but still it is giving me the error.
Ansible VM and the windows VM are both in same VLANs. User account does have admin privileges.
SSL certificates are correctly setup on the windows VM too.
I have whole setup running fine with these versions and configurations but this one server is really paining.
Please suggest…!!
Below are the configuration versions and detailed error message.
PS Version: 4.0
Windows Version: 2008 R2 Standard
Ansible: 2.6.5
Python: 2.7.5
ansible group1 -m win_ping -vvvvv
ansible 2.6.5
config file = /etc/ansible/ansible.cfg
configured module search path = [u’/root/.ansible/plugins/modules’, u’/usr/share/ansible/plugins/modules’]
ansible python module location = /usr/lib/python2.7/site-packages/ansible
executable location = /usr/bin/ansible
python version = 2.7.5 (default, Aug 2 2016, 04:20:16) [GCC 4.8.5 20150623 (Red Hat 4.8.5-4)]
Using /etc/ansible/ansible.cfg as config file
setting up inventory plugins
Loading callback plugin minimal of type stdout, v2.0 from /usr/lib/python2.7/site-packages/ansible/plugins/callback/minimal.pyc
META: ran handlers
Using module file /usr/lib/python2.7/site-packages/ansible/modules/windows/win_ping.ps1
<a.b.c.d> ESTABLISH WINRM CONNECTION FOR USER: administrator on PORT 5986 TO a.b.c.d
checking if winrm_host a.b.c.d is an IPv6 address
<a.b.c.d> WINRM CONNECT: transport=ssl endpoint=https://a.b.c.d:5986/wsman
<a.b.c.d> WINRM CONNECTION ERROR: the specified credentials were rejected by the server
Traceback (most recent call last):
File “/usr/lib/python2.7/site-packages/ansible/plugins/connection/winrm.py”, line 399, in _winrm_connect
self.shell_id = protocol.open_shell(codepage=65001) # UTF-8
File “/usr/lib/python2.7/site-packages/winrm/protocol.py”, line 157, in open_shell
res = self.send_message(xmltodict.unparse(req))
File “/usr/lib/python2.7/site-packages/winrm/protocol.py”, line 234, in send_message
resp = self.transport.send_message(message)
File “/usr/lib/python2.7/site-packages/winrm/transport.py”, line 260, in send_message
response = self._send_message_request(prepared_request, message)
File “/usr/lib/python2.7/site-packages/winrm/transport.py”, line 270, in _send_message_request
raise InvalidCredentialsError(“the specified credentials were rejected by the server”)
InvalidCredentialsError: the specified credentials were rejected by the server
a.b.c.d | UNREACHABLE! => {
“changed”: false,
“msg”: “ssl: the specified credentials were rejected by the server”,
“unreachable”: true
}
Thanks,
Piyush Bansal
9650865898