Comments (4)
Could you verify if the user and group "ansible" is created? From the error it seems the user exist but it cannot be found, quite strange behaviour.
from devops.
Yes it does. See output from the remote machine
root@idp:# grep ansible /etc/passwd# grep ansible /etc/group
ansible:x:1000:1000:ansible user created by bootstrap playbook:/home/ansible:/bin/sh
root@idp:
sudo:x:27:ansible
ansible:x:1000:
root@idp:~#
from devops.
hi Cletus,
can you please run with -vvvv and show us the more verbose output ?
thanks,
Bruce
from devops.
root@ansible:/etc/ansible# ansible-playbook -i inventories/inventory.eko-konnect.net.ng bootstrap.yml -vvv
PLAY [Bootstrap the identity machines] ****************************************
GATHERING FACTS ***************************************************************
<idp.eko-konnect.net.ng> ESTABLISH CONNECTION FOR USER: root
<idp.eko-konnect.net.ng> REMOTE_MODULE setup
<idp.eko-konnect.net.ng> EXEC ['ssh', '-C', '-tt', '-q', '-o', 'ControlMaster=auto', '-o', 'HostbasedAuthentication=yes', '-o', 'StrictHostKeyChecking=no', '-o', 'Port=22', '-o', 'KbdInteractiveAuthentication=no', '-o', 'PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey', '-o', 'PasswordAuthentication=no', '-o', 'ConnectTimeout=10', 'idp.eko-konnect.net.ng', "/bin/sh -c 'mkdir -p $HOME/.ansible/tmp/ansible-tmp-1414084130.67-33401073779926 && echo $HOME/.ansible/tmp/ansible-tmp-1414084130.67-33401073779926'"]
<idp.eko-konnect.net.ng> PUT /tmp/tmpxucT8N TO /root/.ansible/tmp/ansible-tmp-1414084130.67-33401073779926/setup
<idp.eko-konnect.net.ng> EXEC ['ssh', '-C', '-tt', '-q', '-o', 'ControlMaster=auto', '-o', 'HostbasedAuthentication=yes', '-o', 'StrictHostKeyChecking=no', '-o', 'Port=22', '-o', 'KbdInteractiveAuthentication=no', '-o', 'PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey', '-o', 'PasswordAuthentication=no', '-o', 'ConnectTimeout=10', 'idp.eko-konnect.net.ng', u"/bin/sh -c 'LANG=C LC_CTYPE=C /usr/bin/python /root/.ansible/tmp/ansible-tmp-1414084130.67-33401073779926/setup; rm -rf /root/.ansible/tmp/ansible-tmp-1414084130.67-33401073779926/ >/dev/null 2>&1'"]
ok: [idp.eko-konnect.net.ng]
TASK: [bootstrap | check connectivity] ****************************************
<idp.eko-konnect.net.ng> ESTABLISH CONNECTION FOR USER: root
<idp.eko-konnect.net.ng> REMOTE_MODULE command /bin/ping -c 1 www.google.com
<idp.eko-konnect.net.ng> EXEC ['ssh', '-C', '-tt', '-q', '-o', 'ControlMaster=auto', '-o', 'HostbasedAuthentication=yes', '-o', 'StrictHostKeyChecking=no', '-o', 'Port=22', '-o', 'KbdInteractiveAuthentication=no', '-o', 'PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey', '-o', 'PasswordAuthentication=no', '-o', 'ConnectTimeout=10', 'idp.eko-konnect.net.ng', "/bin/sh -c 'mkdir -p $HOME/.ansible/tmp/ansible-tmp-1414084132.26-112946534098841 && echo $HOME/.ansible/tmp/ansible-tmp-1414084132.26-112946534098841'"]
<idp.eko-konnect.net.ng> PUT /tmp/tmpibA7uh TO /root/.ansible/tmp/ansible-tmp-1414084132.26-112946534098841/command
<idp.eko-konnect.net.ng> EXEC ['ssh', '-C', '-tt', '-q', '-o', 'ControlMaster=auto', '-o', 'HostbasedAuthentication=yes', '-o', 'StrictHostKeyChecking=no', '-o', 'Port=22', '-o', 'KbdInteractiveAuthentication=no', '-o', 'PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey', '-o', 'PasswordAuthentication=no', '-o', 'ConnectTimeout=10', 'idp.eko-konnect.net.ng', u"/bin/sh -c 'LANG=C LC_CTYPE=C /usr/bin/python /root/.ansible/tmp/ansible-tmp-1414084132.26-112946534098841/command; rm -rf /root/.ansible/tmp/ansible-tmp-1414084132.26-112946534098841/ >/dev/null 2>&1'"]
changed: [idp.eko-konnect.net.ng] => {"changed": true, "cmd": ["/bin/ping", "-c", "1", "www.google.com"], "delta": "0:00:00.205394", "end": "2014-10-23 13:08:53.800290", "rc": 0, "start": "2014-10-23 13:08:53.594896", "stderr": "", "stdout": "PING www.google.com (74.125.22.99) 56(84) bytes of data.\n64 bytes from qh-in-f99.1e100.net (74.125.22.99): icmp_req=1 ttl=42 time=194 ms\n\n--- www.google.com ping statistics ---\n1 packets transmitted, 1 received, 0% packet loss, time 0ms\nrtt min/avg/max/mdev = 194.366/194.366/194.366/0.000 ms"}
TASK: [bootstrap | use Google public DNS if necessary] ************************
skipping: [idp.eko-konnect.net.ng]
TASK: [bootstrap | Install prerequisite packages (RedHat)] ********************
skipping: [idp.eko-konnect.net.ng]
TASK: [bootstrap | Install some useful packages (RedHat)] *********************
skipping: [idp.eko-konnect.net.ng]
TASK: [bootstrap | Install prerequisite packages (Debian)] ********************
<idp.eko-konnect.net.ng> ESTABLISH CONNECTION FOR USER: root
<idp.eko-konnect.net.ng> REMOTE_MODULE apt name=python-simplejson,iptables,iptables-persistent,mlocate,initscripts,openssh-client state=present
<idp.eko-konnect.net.ng> EXEC ['ssh', '-C', '-tt', '-q', '-o', 'ControlMaster=auto', '-o', 'HostbasedAuthentication=yes', '-o', 'StrictHostKeyChecking=no', '-o', 'Port=22', '-o', 'KbdInteractiveAuthentication=no', '-o', 'PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey', '-o', 'PasswordAuthentication=no', '-o', 'ConnectTimeout=10', 'idp.eko-konnect.net.ng', "/bin/sh -c 'mkdir -p $HOME/.ansible/tmp/ansible-tmp-1414084133.87-151498410370894 && echo $HOME/.ansible/tmp/ansible-tmp-1414084133.87-151498410370894'"]
<idp.eko-konnect.net.ng> PUT /tmp/tmpgdwtmm TO /root/.ansible/tmp/ansible-tmp-1414084133.87-151498410370894/apt
<idp.eko-konnect.net.ng> EXEC ['ssh', '-C', '-tt', '-q', '-o', 'ControlMaster=auto', '-o', 'HostbasedAuthentication=yes', '-o', 'StrictHostKeyChecking=no', '-o', 'Port=22', '-o', 'KbdInteractiveAuthentication=no', '-o', 'PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey', '-o', 'PasswordAuthentication=no', '-o', 'ConnectTimeout=10', 'idp.eko-konnect.net.ng', u"/bin/sh -c 'LANG=C LC_CTYPE=C /usr/bin/python /root/.ansible/tmp/ansible-tmp-1414084133.87-151498410370894/apt; rm -rf /root/.ansible/tmp/ansible-tmp-1414084133.87-151498410370894/ >/dev/null 2>&1'"]
ok: [idp.eko-konnect.net.ng] => (item=python-simplejson,iptables,iptables-persistent,mlocate,initscripts,openssh-client) => {"changed": false, "item": "python-simplejson,iptables,iptables-persistent,mlocate,initscripts,openssh-client"}
TASK: [bootstrap | Install some useful packages (Debian)] *********************
<idp.eko-konnect.net.ng> ESTABLISH CONNECTION FOR USER: root
<idp.eko-konnect.net.ng> REMOTE_MODULE apt name=htop,vim state=present
<idp.eko-konnect.net.ng> EXEC ['ssh', '-C', '-tt', '-q', '-o', 'ControlMaster=auto', '-o', 'HostbasedAuthentication=yes', '-o', 'StrictHostKeyChecking=no', '-o', 'Port=22', '-o', 'KbdInteractiveAuthentication=no', '-o', 'PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey', '-o', 'PasswordAuthentication=no', '-o', 'ConnectTimeout=10', 'idp.eko-konnect.net.ng', "/bin/sh -c 'mkdir -p $HOME/.ansible/tmp/ansible-tmp-1414084135.83-85966915563095 && echo $HOME/.ansible/tmp/ansible-tmp-1414084135.83-85966915563095'"]
<idp.eko-konnect.net.ng> PUT /tmp/tmpdZKEjb TO /root/.ansible/tmp/ansible-tmp-1414084135.83-85966915563095/apt
<idp.eko-konnect.net.ng> EXEC ['ssh', '-C', '-tt', '-q', '-o', 'ControlMaster=auto', '-o', 'HostbasedAuthentication=yes', '-o', 'StrictHostKeyChecking=no', '-o', 'Port=22', '-o', 'KbdInteractiveAuthentication=no', '-o', 'PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey', '-o', 'PasswordAuthentication=no', '-o', 'ConnectTimeout=10', 'idp.eko-konnect.net.ng', u"/bin/sh -c 'LANG=C LC_CTYPE=C /usr/bin/python /root/.ansible/tmp/ansible-tmp-1414084135.83-85966915563095/apt; rm -rf /root/.ansible/tmp/ansible-tmp-1414084135.83-85966915563095/ >/dev/null 2>&1'"]
ok: [idp.eko-konnect.net.ng] => (item=htop,vim) => {"changed": false, "item": "htop,vim"}
TASK: [bootstrap | create ansible user] ***************************************
skipping: [idp.eko-konnect.net.ng]
TASK: [bootstrap | create ansible user] ***************************************
<idp.eko-konnect.net.ng> ESTABLISH CONNECTION FOR USER: root
<idp.eko-konnect.net.ng> REMOTE_MODULE user name=ansible comment="ansible user created by bootstrap playbook" generate_ssh_key=yes groups=sudo
<idp.eko-konnect.net.ng> EXEC ['ssh', '-C', '-tt', '-q', '-o', 'ControlMaster=auto', '-o', 'HostbasedAuthentication=yes', '-o', 'StrictHostKeyChecking=no', '-o', 'Port=22', '-o', 'KbdInteractiveAuthentication=no', '-o', 'PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey', '-o', 'PasswordAuthentication=no', '-o', 'ConnectTimeout=10', 'idp.eko-konnect.net.ng', "/bin/sh -c 'mkdir -p $HOME/.ansible/tmp/ansible-tmp-1414084137.78-183199381627390 && echo $HOME/.ansible/tmp/ansible-tmp-1414084137.78-183199381627390'"]
<idp.eko-konnect.net.ng> PUT /tmp/tmpJpi7XJ TO /root/.ansible/tmp/ansible-tmp-1414084137.78-183199381627390/user
<idp.eko-konnect.net.ng> EXEC ['ssh', '-C', '-tt', '-q', '-o', 'ControlMaster=auto', '-o', 'HostbasedAuthentication=yes', '-o', 'StrictHostKeyChecking=no', '-o', 'Port=22', '-o', 'KbdInteractiveAuthentication=no', '-o', 'PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey', '-o', 'PasswordAuthentication=no', '-o', 'ConnectTimeout=10', 'idp.eko-konnect.net.ng', u"/bin/sh -c 'LANG=C LC_CTYPE=C /usr/bin/python /root/.ansible/tmp/ansible-tmp-1414084137.78-183199381627390/user; rm -rf /root/.ansible/tmp/ansible-tmp-1414084137.78-183199381627390/ >/dev/null 2>&1'"]
ok: [idp.eko-konnect.net.ng] => {"append": false, "changed": false, "comment": "ansible user created by bootstrap playbook", "group": 1000, "groups": "sudo", "home": "/home/ansible", "move_home": false, "name": "ansible", "shell": "/bin/sh", "ssh_fingerprint": "2048 83:11:5b:d5:32:2f:67:7d:b3:1f:92:c5:8c:61:69:7b ansible-generated (RSA)", "ssh_key_file": "/home/ansible/.ssh/id_rsa", "ssh_public_key": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDPK02T1qMn/P5ygOZhVp/jdo5kNZ6N3DSiSzaM7hSS14CUQqljCp7ivVMFfidUAThPzlRpQnr62Hl+yULVny8iXzehtabaW4Jmm/DYs6sr3tBN/F4xA/+GfQBw8WsnhNcblUppSjXNXifzyEE6JWo59pYxDd2SUni9B137Jvw5p7oEyyO4hNPYheHTL7NnYfiSMvRx5A8YV6ugmJ0AY6/VMxNWK8yH4ikG+pBw/hSVroMKw9hZGO2BCzzP1w8ADu8pENCaDEt8yb/TcxsvLK+ZfBgmx9CCE7kS80UbP3NSQh7a5Hu6YmGrWpK19N/elOQU1SS1eLLIX7fYAVyzVxjl ansible-generated", "state": "present", "uid": 1000}
TASK: [bootstrap | update sudoers to ensure ansible user can sudo] ************
<idp.eko-konnect.net.ng> ESTABLISH CONNECTION FOR USER: root
<idp.eko-konnect.net.ng> REMOTE_MODULE lineinfile dest=/etc/sudoers state=present regexp='^ansible' line='ansible ALL=(ALL) NOPASSWD: ALL'
<idp.eko-konnect.net.ng> EXEC ['ssh', '-C', '-tt', '-q', '-o', 'ControlMaster=auto', '-o', 'HostbasedAuthentication=yes', '-o', 'StrictHostKeyChecking=no', '-o', 'Port=22', '-o', 'KbdInteractiveAuthentication=no', '-o', 'PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey', '-o', 'PasswordAuthentication=no', '-o', 'ConnectTimeout=10', 'idp.eko-konnect.net.ng', "/bin/sh -c 'mkdir -p $HOME/.ansible/tmp/ansible-tmp-1414084139.15-21619716252787 && echo $HOME/.ansible/tmp/ansible-tmp-1414084139.15-21619716252787'"]
<idp.eko-konnect.net.ng> PUT /tmp/tmped1Fso TO /root/.ansible/tmp/ansible-tmp-1414084139.15-21619716252787/lineinfile
<idp.eko-konnect.net.ng> EXEC ['ssh', '-C', '-tt', '-q', '-o', 'ControlMaster=auto', '-o', 'HostbasedAuthentication=yes', '-o', 'StrictHostKeyChecking=no', '-o', 'Port=22', '-o', 'KbdInteractiveAuthentication=no', '-o', 'PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey', '-o', 'PasswordAuthentication=no', '-o', 'ConnectTimeout=10', 'idp.eko-konnect.net.ng', u"/bin/sh -c 'LANG=C LC_CTYPE=C /usr/bin/python /root/.ansible/tmp/ansible-tmp-1414084139.15-21619716252787/lineinfile; rm -rf /root/.ansible/tmp/ansible-tmp-1414084139.15-21619716252787/ >/dev/null 2>&1'"]
ok: [idp.eko-konnect.net.ng] => {"backup": "", "changed": false, "msg": ""}
TASK: [bootstrap | create the authorized_keys file for the site] **************
<idp.eko-konnect.net.ng> ESTABLISH CONNECTION FOR USER: root
<idp.eko-konnect.net.ng> EXEC ['ssh', '-C', '-tt', '-q', '-o', 'ControlMaster=auto', '-o', 'HostbasedAuthentication=yes', '-o', 'StrictHostKeyChecking=no', '-o', 'Port=22', '-o', 'KbdInteractiveAuthentication=no', '-o', 'PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey', '-o', 'PasswordAuthentication=no', '-o', 'ConnectTimeout=10', 'idp.eko-konnect.net.ng', "/bin/sh -c 'mkdir -p $HOME/.ansible/tmp/ansible-tmp-1414084140.53-187937154697348 && echo $HOME/.ansible/tmp/ansible-tmp-1414084140.53-187937154697348'"]
<idp.eko-konnect.net.ng> EXEC ['ssh', '-C', '-tt', '-q', '-o', 'ControlMaster=auto', '-o', 'HostbasedAuthentication=yes', '-o', 'StrictHostKeyChecking=no', '-o', 'Port=22', '-o', 'KbdInteractiveAuthentication=no', '-o', 'PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey', '-o', 'PasswordAuthentication=no', '-o', 'ConnectTimeout=10', 'idp.eko-konnect.net.ng', u'/bin/sh -c 'rc=0; [ -r "/home/ansible/.ssh/authorized_keys" ] || rc=2; [ -f "/home/ansible/.ssh/authorized_keys" ] || rc=1; [ -d "/home/ansible/.ssh/authorized_keys" ] && echo 3 && exit 0; (/usr/bin/md5sum /home/ansible/.ssh/authorized_keys 2>/dev/null) || (/sbin/md5sum -q /home/ansible/.ssh/authorized_keys 2>/dev/null) || (/usr/bin/digest -a md5 /home/ansible/.ssh/authorized_keys 2>/dev/null) || (/sbin/md5 -q /home/ansible/.ssh/authorized_keys 2>/dev/null) || (/usr/bin/md5 -n /home/ansible/.ssh/authorized_keys 2>/dev/null) || (/bin/md5 -q /home/ansible/.ssh/authorized_keys 2>/dev/null) || (/usr/bin/csum -h MD5 /home/ansible/.ssh/authorized_keys 2>/dev/null) || (/bin/csum -h MD5 /home/ansible/.ssh/authorized_keys 2>/dev/null) || (echo "${rc} /home/ansible/.ssh/authorized_keys")'']
<idp.eko-konnect.net.ng> PUT /tmp/tmpSjY6tI TO /root/.ansible/tmp/ansible-tmp-1414084140.53-187937154697348/src
<idp.eko-konnect.net.ng> PUT /tmp/tmpFkYRYl TO /root/.ansible/tmp/ansible-tmp-1414084140.53-187937154697348/copy
<idp.eko-konnect.net.ng> EXEC ['ssh', '-C', '-tt', '-q', '-o', 'ControlMaster=auto', '-o', 'HostbasedAuthentication=yes', '-o', 'StrictHostKeyChecking=no', '-o', 'Port=22', '-o', 'KbdInteractiveAuthentication=no', '-o', 'PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey', '-o', 'PasswordAuthentication=no', '-o', 'ConnectTimeout=10', 'idp.eko-konnect.net.ng', u"/bin/sh -c 'LANG=C LC_CTYPE=C /usr/bin/python /root/.ansible/tmp/ansible-tmp-1414084140.53-187937154697348/copy; rm -rf /root/.ansible/tmp/ansible-tmp-1414084140.53-187937154697348/ >/dev/null 2>&1'"]
failed: [idp.eko-konnect.net.ng] => {"failed": true, "gid": 0, "group": "root", "mode": "0644", "owner": "root", "path": "/home/ansible/.ssh/authorized_keys", "size": 791, "state": "file", "uid": 0}
msg: chown failed: failed to look up user ansible:ansible
FATAL: all hosts have already failed -- aborting
PLAY RECAP ********************************************************************
to retry, use: --limit @/root/bootstrap.retry
idp.eko-konnect.net.ng : ok=6 changed=1 unreachable=0 failed=1
from devops.
Related Issues (20)
- vulnerability scans for ARGUS
- Child group is not defined HOT 4
- become is not a legal parameter HOT 5
- ldap server issue HOT 1
- Shibboleth version HOT 2
- Permission denied error on remote machine. HOT 2
- Clarification on ansible user HOT 1
- Update the License to explicitly accept contributions
- Use the new UMD role
- test CODE-RADE for openstack across multiple OS's
- Deployment strategy HOT 1
- private submodules are breaking the build. HOT 1
- YAMLlint failures in Travis testing HOT 1
- Compute nodes powered up
- network containers
- undercloud deployment
- UJ WN IP list
- ZeroMQ dependency error on Undercloud install HOT 2
- build-machines #5 failed HOT 1
- Dependency Dashboard
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from devops.