# Authentication or Permission Failure

**URL:** <https://forum.ansible.com/t/authentication-or-permission-failure/21882>\
**Category:** Ansible Project\
**Tags:** ubuntu\
**Created:** [June 28, 2016, 8:01pm UTC](https://forum.ansible.com/t/authentication-or-permission-failure/21882 "2016-06-28T20:01:35Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![brendan\_maynard](https://avatars.discourse-cdn.com/v4/letter/b/bc8723/32.png) [@brendan\_maynard](https://forum.ansible.com/u/brendan_maynard)\
**Post date:** [June 28, 2016, 8:01pm UTC](https://forum.ansible.com/t/authentication-or-permission-failure/21882/1 "2016-06-28T20:01:35Z")

</div>

I am getting a issue that appears to be a file E & W error on my local machine when executing simple ad hoc modules (i.e. ping) -

test@ubuntu:~$ ansible hosts -m ping -vvvv  
Using /etc/ansible/ansible.cfg as config file  
Loaded callback minimal of type stdout, v2.0  
\<192.168.56.236\> ESTABLISH SSH CONNECTION FOR USER: test  
\<192.168.56.236\> SSH: EXEC ssh -C -vvv -o ControlMaster=auto -o ControlPersist=60s -o StrictHostKeyChecking=no -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o User=test -o ConnectTimeout=10 -o ControlPath=/home/test/.ansible/cp/ansible-ssh-%h-%p-%r 192.168.56.236 ‘/bin/sh -c ‘"’"’( umask 77 && mkdir -p “`echo /tmp/ansible-tmp-1467143557.54-130391232423944`” && echo ansible-tmp-1467143557.54-130391232423944=“`echo /tmp/ansible-tmp-1467143557.54-130391232423944`” ) && sleep 0’“'”‘’  
}  
192.168.56.236 | UNREACHABLE! =\> {  
“changed”: false,  
“msg”: “Authentication or permission failure. In some cases, you may have been able to authenticate and did not have permissions on the remote directory. Consider changing the remote temp path in ansible.cfg to a path rooted in "/tmp". Failed command was: ( umask 77 && mkdir -p "`echo /tmp/ansible-tmp-1467143557.54-130391232423944`" && echo ansible-tmp-1467143557.54-130391232423944="`echo /tmp/ansible-tmp-1467143557.54-130391232423944`" ), exited with result 16: Syntax error while parsing ‘/bin/sh -c ‘( umask 77 && mkdir -p "`echo /tmp/ansible-tmp-1467143557.54-130391232423944`" && echo ansible-tmp-1467143557.54-130391232423944="`echo /tmp/ansible-tmp-1467143557.54-130391232423944`" ) && sleep 0’’\n\n\nCmd exec error.\n”,  
“unreachable”: true

I can SSH from my machines to the localhost, and from the local host to the machines via public key. I can also create the directory above with no issue… I have changed the remote\_tmp directory to /tmp, and it has 1777 privileges…

---

<div class="post-metadata">

**Author:** ![brendan\_maynard](https://avatars.discourse-cdn.com/v4/letter/b/bc8723/32.png) [@brendan\_maynard](https://forum.ansible.com/u/brendan_maynard)\
**Post date:** [June 28, 2016, 8:33pm UTC](https://forum.ansible.com/t/authentication-or-permission-failure/21882/2 "2016-06-28T20:33:32Z")

</div>

I am running ansible version 2.1.0.0
