Hi all,
Previously with docker version 17.12 this error was not reproduced
but now after the docker-ce version is updated which is 18.01
The prechecks fail with the following error.
Logs in Verbose mode:
TASK [prechecks : Checking Docker version] **************************************************************************************************************************************************************************************************
task path: /usr/local/share/kolla-ansible/ansible/roles/prechecks/tasks/service_checks.yml:2
skipping: [localhost] => {
"changed": false,
"skip_reason": "Conditional result was False",
"skipped": true
}
Using module file /usr/local/lib/python2.7/dist-packages/ansible/modules/commands/command.py
<192.168.0.16> ESTABLISH SSH CONNECTION FOR USER: None
<192.168.0.16> SSH: EXEC ssh -C -o ControlMaster=auto -o ControlPersist=60s -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o ConnectTimeout=10 -o ControlPath=/root/.ansible/cp/b3ef988f96 192.168.0.16 '/bin/sh -c '"'"'echo ~ && sleep 0'"'"''
Using module file /usr/local/lib/python2.7/dist-packages/ansible/modules/commands/command.py
<192.168.0.20> ESTABLISH SSH CONNECTION FOR USER: None
<192.168.0.20> SSH: EXEC ssh -C -o ControlMaster=auto -o ControlPersist=60s -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o ConnectTimeout=10 -o ControlPath=/root/.ansible/cp/505563c6ef 192.168.0.20 '/bin/sh -c '"'"'echo ~ && sleep 0'"'"''
<192.168.0.16> (0, '/root\n', '')
<192.168.0.16> ESTABLISH SSH CONNECTION FOR USER: None
<192.168.0.16> SSH: EXEC ssh -C -o ControlMaster=auto -o ControlPersist=60s -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o ConnectTimeout=10 -o ControlPath=/root/.ansible/cp/b3ef988f96 192.168.0.16 '/bin/sh -c '"'"'( umask 77 && mkdir -p "` echo /root/.ansible/tmp/ansible-tmp-1515663389.35-208892213749322 `" && echo ansible-tmp-1515663389.35-208892213749322="` echo /root/.ansible/tmp/ansible-tmp-1515663389.35-208892213749322 `" ) && sleep 0'"'"''
<192.168.0.20> (0, '/root\n', '')
<192.168.0.20> ESTABLISH SSH CONNECTION FOR USER: None
<192.168.0.20> SSH: EXEC ssh -C -o ControlMaster=auto -o ControlPersist=60s -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o ConnectTimeout=10 -o ControlPath=/root/.ansible/cp/505563c6ef 192.168.0.20 '/bin/sh -c '"'"'( umask 77 && mkdir -p "` echo /root/.ansible/tmp/ansible-tmp-1515663389.37-16642865815880 `" && echo ansible-tmp-1515663389.37-16642865815880="` echo /root/.ansible/tmp/ansible-tmp-1515663389.37-16642865815880 `" ) && sleep 0'"'"''
<192.168.0.16> (0, 'ansible-tmp-1515663389.35-208892213749322=/root/.ansible/tmp/ansible-tmp-1515663389.35-208892213749322\n', '')
<192.168.0.16> PUT /tmp/tmpjplqyL TO /root/.ansible/tmp/ansible-tmp-1515663389.35-208892213749322/command.py
<192.168.0.16> SSH: EXEC sftp -b - -C -o ControlMaster=auto -o ControlPersist=60s -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o ConnectTimeout=10 -o ControlPath=/root/.ansible/cp/b3ef988f96 '[192.168.0.16]'
<192.168.0.20> (0, 'ansible-tmp-1515663389.37-16642865815880=/root/.ansible/tmp/ansible-tmp-1515663389.37-16642865815880\n', '')
<192.168.0.20> PUT /tmp/tmpdEH1aP TO /root/.ansible/tmp/ansible-tmp-1515663389.37-16642865815880/command.py
<192.168.0.20> SSH: EXEC sftp -b - -C -o ControlMaster=auto -o ControlPersist=60s -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o ConnectTimeout=10 -o ControlPath=/root/.ansible/cp/505563c6ef '[192.168.0.20]'
<192.168.0.16> (0, 'sftp> put /tmp/tmpjplqyL /root/.ansible/tmp/ansible-tmp-1515663389.35-208892213749322/command.py\n', '')
<192.168.0.16> ESTABLISH SSH CONNECTION FOR USER: None
<192.168.0.16> SSH: EXEC ssh -C -o ControlMaster=auto -o ControlPersist=60s -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o ConnectTimeout=10 -o ControlPath=/root/.ansible/cp/b3ef988f96 192.168.0.16 '/bin/sh -c '"'"'chmod u+x /root/.ansible/tmp/ansible-tmp-1515663389.35-208892213749322/ /root/.ansible/tmp/ansible-tmp-1515663389.35-208892213749322/command.py && sleep 0'"'"''
<192.168.0.20> (0, 'sftp> put /tmp/tmpdEH1aP /root/.ansible/tmp/ansible-tmp-1515663389.37-16642865815880/command.py\n', '')
<192.168.0.20> ESTABLISH SSH CONNECTION FOR USER: None
<192.168.0.20> SSH: EXEC ssh -C -o ControlMaster=auto -o ControlPersist=60s -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o ConnectTimeout=10 -o ControlPath=/root/.ansible/cp/505563c6ef 192.168.0.20 '/bin/sh -c '"'"'chmod u+x /root/.ansible/tmp/ansible-tmp-1515663389.37-16642865815880/ /root/.ansible/tmp/ansible-tmp-1515663389.37-16642865815880/command.py && sleep 0'"'"''
<192.168.0.16> (0, '', '')
<192.168.0.16> ESTABLISH SSH CONNECTION FOR USER: None
<192.168.0.16> SSH: EXEC ssh -C -o ControlMaster=auto -o ControlPersist=60s -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o ConnectTimeout=10 -o ControlPath=/root/.ansible/cp/b3ef988f96 -tt 192.168.0.16 '/bin/sh -c '"'"'/usr/bin/python /root/.ansible/tmp/ansible-tmp-1515663389.35-208892213749322/command.py; rm -rf "/root/.ansible/tmp/ansible-tmp-1515663389.35-208892213749322/" > /dev/null 2>&1 && sleep 0'"'"''
<192.168.0.20> (0, '', '')
<192.168.0.20> ESTABLISH SSH CONNECTION FOR USER: None
<192.168.0.20> SSH: EXEC ssh -C -o ControlMaster=auto -o ControlPersist=60s -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o ConnectTimeout=10 -o ControlPath=/root/.ansible/cp/505563c6ef -tt 192.168.0.20 '/bin/sh -c '"'"'/usr/bin/python /root/.ansible/tmp/ansible-tmp-1515663389.37-16642865815880/command.py; rm -rf "/root/.ansible/tmp/ansible-tmp-1515663389.37-16642865815880/" > /dev/null 2>&1 && sleep 0'"'"''
<192.168.0.16> (0, '\r\n{"changed": true, "end": "2018-01-11 10:36:28.924521", "stdout": "Client:\\n Version:\\t18.01.0-ce\\n API version:\\t1.35\\n Go version:\\tgo1.9.2\\n Git commit:\\t03596f5\\n Built:\\tWed Jan 10 20:11:05 2018\\n OS/Arch:\\tlinux/amd64\\n Experimental:\\tfalse\\n Orchestrator:\\tswarm\\n\\nServer:\\n Engine:\\n Version:\\t18.01.0-ce\\n API version:\\t1.35 (minimum version 1.12)\\n Go version:\\tgo1.9.2\\n Git commit:\\t03596f5\\n Built:\\tWed Jan 10 20:09:37 2018\\n OS/Arch:\\tlinux/amd64\\n Experimental:\\tfalse", "cmd": ["docker", "version"], "rc": 0, "start": "2018-01-11 10:36:28.846038", "stderr": "", "delta": "0:00:00.078483", "invocation": {"module_args": {"warn": true, "executable": null, "_uses_shell": false, "_raw_params": "docker version", "removes": null, "creates": null, "chdir": null, "stdin": null}}}\r\n', 'Shared connection to 192.168.0.16 closed.\r\n')
fatal: [192.168.0.16]: FAILED! => {
"failed": true,
"msg": "The conditional check 'result | failed or (result.stdout | from_yaml).Server.Version | regex_replace('(\\\\d+\\\\.\\\\d+\\\\.\\\\d+).*', '\\\\1') | version_compare(docker_version_min, '<')' failed. The error was: while scanning for the next token\nfound character '\\t' that cannot start any token\n in \"<unicode string>\", line 2, column 10:\n Version:\t18.01.0-ce\n ^"
}
<192.168.0.20> (0, '\r\n{"changed": true, "end": "2018-01-11 10:36:34.092049", "stdout": "Client:\\n Version:\\t18.01.0-ce\\n API version:\\t1.35\\n Go version:\\tgo1.9.2\\n Git commit:\\t03596f5\\n Built:\\tWed Jan 10 20:11:05 2018\\n OS/Arch:\\tlinux/amd64\\n Experimental:\\tfalse\\n Orchestrator:\\tswarm\\n\\nServer:\\n Engine:\\n Version:\\t18.01.0-ce\\n API version:\\t1.35 (minimum version 1.12)\\n Go version:\\tgo1.9.2\\n Git commit:\\t03596f5\\n Built:\\tWed Jan 10 20:09:37 2018\\n OS/Arch:\\tlinux/amd64\\n Experimental:\\tfalse", "cmd": ["docker", "version"], "rc": 0, "start": "2018-01-11 10:36:34.011192", "stderr": "", "delta": "0:00:00.080857", "invocation": {"module_args": {"warn": true, "executable": null, "_uses_shell": false, "_raw_params": "docker version", "removes": null, "creates": null, "chdir": null, "stdin": null}}}\r\n', 'Shared connection to 192.168.0.20 closed.\r\n')
fatal: [192.168.0.20]: FAILED! => {
"failed": true,
"msg": "The conditional check 'result | failed or (result.stdout | from_yaml).Server.Version | regex_replace('(\\\\d+\\\\.\\\\d+\\\\.\\\\d+).*', '\\\\1') | version_compare(docker_version_min, '<')' failed. The error was: while scanning for the next token\nfound character '\\t' that cannot start any token\n in \"<unicode string>\", line 2, column 10:\n Version:\t18.01.0-ce\n ^"
}
I feel it is probably because of this
Version:\t18.01.0-ce\n
Thanks in Advance.
Akshay.
Fix proposed to branch: master /review. openstack. org/533339
Review: https:/