Hi, that is a very odd error, as it's failing to parse XML returned and
appears to be connecting to the https port but is using the http protocol
(thus the binary output) at the end. Can you share your python winrm
version and any other relevant details in regards to how you have your
inventory configured?

James Cammarata
Director, Ansible Core Engineering
github: jimi-c

On Sun, May 31, 2015 at 10:59 AM, <[email protected]> wrote:

> I can't seem to get anything to work over winrm.  I keep getting this
> error no matter what I try. I have run the setup scripts.
>
> [ansible-stuff]$ ansible -i inventory windows7-ansible4 -m setup -vvvv
> <windows7-ansible4> ESTABLISH WINRM CONNECTION FOR USER: stew on PORT 5986
> TO windows7-ansible4
> <windows7-ansible4> WINRM CONNECT: transport=plaintext endpoint=
> https://windows7-ansible4:5986/wsman
> <windows7-ansible4> REMOTE_MODULE setup
> <windows7-ansible4> EXEC (New-Item -Type Directory -Path $env:temp -Name
> "ansible-tmp-1433087659.28-74445365416872").FullName | Write-Host
> -Separator '';
> <windows7-ansible4> WINRM EXEC 'PowerShell' ['-NoProfile',
> '-NonInteractive', '-EncodedCommand',
> 'KABOAGUAdwAtAEkAdABlAG0AIAAtAFQAeQBwAGUAIABEAGkAcgBlAGMAdABvAHIAeQAgAC0AUABhAHQAaAAgACQAZQBuAHYAOgB0AGUAbQBwACAALQBOAGEAbQBlACAAIgBhAG4AcwBpAGIAbABlAC0AdABtAHAALQAxADQAMwAzADAAOAA3ADYANQA5AC4AMgA4AC0ANwA0ADQANAA1ADMANgA1ADQAMQA2ADgANwAyACIAKQAuAEYAdQBsAGwATgBhAG0AZQAgAHwAIABXAHIAaQB0AGUALQBIAG8AcwB0ACAALQBTAGUAcABhAHIAYQB0AG8AcgAgACcAJwA7AA==']
> Traceback (most recent call last):
>   File
> "/usr/lib/python2.6/site-packages/ansible/runner/connection_plugins/winrm.py",
> line 161, in exec_command
>     result = self._winrm_exec(cmd_parts[0], cmd_parts[1:], from_exec=True)
>   File
> "/usr/lib/python2.6/site-packages/ansible/runner/connection_plugins/winrm.py",
> line 122, in _winrm_exec
>     self.shell_id = self.protocol.open_shell()
>   File "/usr/lib/python2.6/site-packages/winrm/protocol.py", line 121, in
> open_shell
>     root = ET.fromstring(rs)
>   File "/usr/lib64/python2.6/xml/etree/ElementTree.py", line 963, in XML
>     parser.feed(text)
>   File "/usr/lib64/python2.6/xml/etree/ElementTree.py", line 1245, in feed
>     self._parser.Parse(data, 0)
>   File "/usr/lib64/python2.6/xml/etree/ElementTree.py", line 1188, in _end
>     return self._target.end(self._fixname(tag))
>   File "/usr/lib64/python2.6/xml/etree/ElementTree.py", line 1096, in end
>     self._last.tag, tag)
> AssertionError: end tag mismatch (expected
> ▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒𐁽▒▒n򤃰򥷠▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒羸򩻀򫌀 򥸀󳱰, got
> ▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒𐁽▒▒n▒▒2B▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒⸾)
> windows7-ansible4 | FAILED => failed to exec cmd PowerShell -NoProfile
> -NonInteractive -EncodedCommand
> KABOAGUAdwAtAEkAdABlAG0AIAAtAFQAeQBwAGUAIABEAGkAcgBlAGMAdABvAHIAeQAgAC0AUABhAHQAaAAgACQAZQBuAHYAOgB0AGUAbQBwACAALQBOAGEAbQBlACAAIgBhAG4AcwBpAGIAbABlAC0AdABtAHAALQAxADQAMwAzADAAOAA3ADYANQA5AC4AMgA4AC0ANwA0ADQANAA1ADMANgA1ADQAMQA2ADgANwAyACIAKQAuAEYAdQBsAGwATgBhAG0AZQAgAHwAIABXAHIAaQB0AGUALQBIAG8AcwB0ACAALQBTAGUAcABhAHIAYQB0AG8AcgAgACcAJwA7AA==
>
> --
> 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/b4531610-65a4-4763-b039-ebfa256b44ce%40googlegroups.com
> <https://groups.google.com/d/msgid/ansible-project/b4531610-65a4-4763-b039-ebfa256b44ce%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 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/CAMFyvFiZipMeLAbzwX4SbOuEaopU87b6gQXMOJHNNYS%3DOTNHkw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to