ansible 1.7.1 (this and other details are in the original posting)
On Mon, Sep 29, 2014 at 7:03 AM, Michael DeHaan <[email protected]> wrote: > ansible_ssh_host does not imply the transport. > > Let's ask the starter question, "what's the output of ansible --version" ? > > > > On Mon, Sep 29, 2014 at 6:36 AM, J Hawkesworth < > [email protected]> wrote: > >> Try not setting the ansible_ssh_host in your inventory - I think this >> might be forcing it to attempt ssh transport, which of course isn't going >> to work for windows hosts. >> >> In other words, change >> >> [ads800s] >> ADS-6999 ansible_ssh_host=123.123.123.123 >> >> to >> >> ads800s] >> ADS-6999 >> >> and ensure ADS-6999 can either be resolved by your local dns or as an >> entry in /etc/hosts >> >> >> On Wednesday, September 24, 2014 3:51:28 PM UTC+1, skinnedknuckles wrote: >>> >>> >>> I'm having trouble getting win_ping to work. Here is my info: >>> Fedora 20 >>> Ansible 1.7.1 >>> Remote node running windows 7 >>> The WinRM script by Trond runs without errors on the remote node >>> Control and Remote Machines are both on Lan with common domain w/o >>> firewalls >>> So far as I can tell I've installed everything on control and remote >>> machine as described in documentation >>> >>> My inventory file contains >>> [ads800s] >>> ADS-6999 ansible_ssh_host=123.123.123.123 >>> >>> My windows.yml file is in the group_vars directory and contains >>> ansible_ssh_user: ansmgr >>> ansible_ssh_pass: ansiblepw >>> ansible_ssh_port: 5986 >>> ansible_connection: winrm >>> >>> Can you tell what I'm doing wrong? Do you need any more information? >>> >>> Here is the debugging output of my win_ping command (with -c winrm is >>> below) >>> >>> [ansmgr@LinuxControlMachine ansible]$ ansible ADS-6999 -m win_ping -vvvv >>> <123.123.123.123> ESTABLISH CONNECTION FOR USER: ansmgr >>> <123.123.123.123> REMOTE_MODULE win_ping >>> <123.123.123.123> EXEC ['ssh', '-C', '-tt', '-vvv', '-o', >>> 'ControlMaster=auto', '-o', 'ControlPersist=60s', '-o', >>> 'ControlPath=/home/ansmgr/.ansible/cp/ansible-ssh-%h-%p-%r', '-o', >>> 'Port=22', '-o', 'KbdInteractiveAuthentication=no', '-o', >>> 'PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey', >>> '-o', 'PasswordAuthentication=no', '-o', 'ConnectTimeout=10', >>> '123.123.123.123', "/bin/sh -c 'mkdir -p $HOME/.ansible/tmp/ansible- >>> tmp-1411567957.01-192759344617423 && chmod a+rx >>> $HOME/.ansible/tmp/ansible-tmp-1411567957.01-192759344617423 && echo >>> $HOME/.ansible/tmp/ansible-tmp-1411567957.01-192759344617423'"] >>> ADS-6999 | FAILED => SSH encountered an unknown error. The output was: >>> OpenSSH_6.4, OpenSSL 1.0.1e-fips 11 Feb 2013 >>> debug1: Reading configuration data /etc/ssh/ssh_config >>> debug1: /etc/ssh/ssh_config line 51: Applying options for * >>> debug1: auto-mux: Trying existing master >>> debug1: Control socket "/home/ansmgr/.ansible/cp/ >>> ansible-ssh-123.123.123.123-22-ansmgr" does not exist >>> debug2: ssh_connect: needpriv 0 >>> debug1: Connecting to 123.123.123.123 [123.123.123.123] port 22. >>> debug2: fd 3 setting O_NONBLOCK >>> debug1: connect to address 123.123.123.123 port 22: Connection refused >>> ssh: connect to host 123.123.123.123 port 22: Connection refused >>> >>> Here is the debugging output of my win_ping command with -c winrm is >>> below >>> >>> [ansmgr@LinuxControlMachine ansible]$ ansible ADS-6999 -c winrm -m >>> win_ping -vvvv >>> <123.123.123.123> ESTABLISH WINRM CONNECTION FOR USER: ansmgr on PORT >>> 5986 TO 123.123.123.123 >>> ADS-6999 | FAILED => Traceback (most recent call last): >>> File "/usr/lib/python2.7/site-packages/ansible/runner/__init__.py", >>> line 561, in _executor >>> exec_rc = self._executor_internal(host, new_stdin) >>> File "/usr/lib/python2.7/site-packages/ansible/runner/__init__.py", >>> line 666, in _executor_internal >>> return self._executor_internal_inner(host, self.module_name, >>> self.module_args, inject, port, complex_args=complex_args) >>> File "/usr/lib/python2.7/site-packages/ansible/runner/__init__.py", >>> line 837, in _executor_internal_inner >>> conn = self.connector.connect(actual_host, actual_port, >>> actual_user, actual_pass, actual_transport, actual_private_key_file) >>> File "/usr/lib/python2.7/site-packages/ansible/runner/connection.py", >>> line 34, in connect >>> self.active = conn.connect() >>> File >>> "/usr/lib/python2.7/site-packages/ansible/runner/connection_plugins/winrm.py", >>> line 132, in connect >>> self.protocol = self._winrm_connect() >>> File >>> "/usr/lib/python2.7/site-packages/ansible/runner/connection_plugins/winrm.py", >>> line 71, in _winrm_connect >>> cache_key = '%s:%s@%s:%d' % (self.user, >>> hashlib.md5(self.password).hexdigest(), >>> self.host, port) >>> TypeError: md5() argument 1 must be string or buffer, not None >>> >>> >>> -- >> 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/0c52c661-746a-44b9-8bc3-805bcbf006fc%40googlegroups.com >> <https://groups.google.com/d/msgid/ansible-project/0c52c661-746a-44b9-8bc3-805bcbf006fc%40googlegroups.com?utm_medium=email&utm_source=footer> >> . >> >> For more options, visit https://groups.google.com/d/optout. >> > > -- > You received this message because you are subscribed to a topic in the > Google Groups "Ansible Project" group. > To unsubscribe from this topic, visit > https://groups.google.com/d/topic/ansible-project/mXsqZp6oiV0/unsubscribe. > To unsubscribe from this group and all its topics, 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/CA%2BnsWgxObC7FUMCBXBb3Dch8Ar7vD7dML4YeNMJfRtbTOa1PKw%40mail.gmail.com > <https://groups.google.com/d/msgid/ansible-project/CA%2BnsWgxObC7FUMCBXBb3Dch8Ar7vD7dML4YeNMJfRtbTOa1PKw%40mail.gmail.com?utm_medium=email&utm_source=footer> > . > > For more options, visit https://groups.google.com/d/optout. > -- 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/CAC-wQgHxZePQUA-s4jrbmBuW%3DdwOW_-7t%3DtPoPX-uh_05tRO9Q%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
