我已经通过pip在virtualenv中安装了ansible 1.9.4。我正在尝试执行一个基本命令:
ansible -i hosts all -m shell -a "uptime" -k
SSH password:
响应:
192.168.2.100 | FAILED >> {
"failed": true,
"msg": "Traceback (most recent call last):\r\n File \"/home/romaan/.ansible/tmp/ansible-tmp-1448629926.2-272544062445748/command\", line 303, in <module>\r\n import json\r\n File \"/usr/lib/python2.7/json/__init__.py\", line 108, in <module>\r\n from .decoder import JSONDecoder\r\n File \"/usr/lib/python2.7/json/decoder.py\", line 24, in <module>\r\n NaN, PosInf, NegInf = _floatconstants()\r\n File \"/usr/lib/python2.7/json/decoder.py\", line 18, in _floatconstants\r\n _BYTES = '7FF80000000000007FF0000000000000'.decode('hex')\r\n File \"/usr/lib/python2.7/encodings/__init__.py\", line 100, in search_function\r\n level=0)\r\nEOFError: EOF read where object expected\r\nOpenSSH_6.6.1, OpenSSL 1.0.1f 6 Jan 2014\r\ndebug1: Reading configuration data /etc/ssh/ssh_config\r\ndebug1: /etc/ssh/ssh_config line 19: Applying options for *\r\ndebug1: auto-mux: Trying existing master\r\ndebug1: mux_client_request_session: master session id: 2\r\nShared connection to 192.168.2.100 closed.\r\n",
"parsed": false
}
我的“主机”文件有192.168.2.100
我已确认可以通过ssh手动登录此IP。
请帮助我理解为什么我收到此错误,我该如何解决?