BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
Asif4862
Quartz | Level 8

Hello All, 

During SAS Viya 3.4 installation on AWS Linux node having that error message at the end

fatal: [deployTarget]: FAILED! => {"changed": false, "msg": "Failed to create remote module tmp path at dir /tmp/.root.ansible/ with prefix ansible-moduletmp-1567623975.36-: [Errno 13] Permission denied: '/tmp/.root.ansible/ansible-moduletmp-1567623975.36-N_Ec8S'"}
2019-09-04 19:06:15,380 p=18476 u=root | NO MORE HOSTS LEFT *************************************************************
2019-09-04 19:06:15,381 p=18476 u=root | PLAY RECAP *********************************************************************
2019-09-04 19:06:15,381 p=18476 u=root | deployTarget : ok=208 changed=65 unreachable=0 failed=1
2019-09-04 19:06:15,381 p=18476 u=root | localhost : ok=14 changed=1 unreachable=0 failed=0

 

Please advise

Thanks in advance

Thanks,
Asif

1 ACCEPTED SOLUTION

Accepted Solutions
jeromesauve
Fluorite | Level 6

Hello,

 

Hope you resolved your issu. 

 

This can happen when you run the ansible-playbook with sudo. You should instead run it as a normal user, but use the switch to give ansible your sudo password.

 

Regard,

 

Jérôme

View solution in original post

9 REPLIES 9
willhaley
Calcite | Level 5

Ran into this same issue.  The work around I figured out was to set the permissions for the /tmp/.root.ansible directory to 777.  

 

sudo chmod -R 777 /tmp/.root.ansible
Asif4862
Quartz | Level 8

Thanks Willhaley, I'll definitely apply your resolution step and i'll let you know with end results.

Thanks for your help

Appreciated 🙂 

Asif4862
Quartz | Level 8

I tried your solution @willhaley but still having same error msg. I don't know what is the issue

Thanks,
Asif  

jeromesauve
Fluorite | Level 6

Hello,

 

Hope you resolved your issu. 

 

This can happen when you run the ansible-playbook with sudo. You should instead run it as a normal user, but use the switch to give ansible your sudo password.

 

Regard,

 

Jérôme

Iyappan21
Obsidian | Level 7
@jeromesauve I am doing the same and the issue is still there. We are installing with normal user with sudo password still we face the issue. Can you please explain the solution If we miss any.
Kindly Guide.

Thanks,
Iyappan M S
Iyappan21
Obsidian | Level 7

Hi All,

Another solution for this issue. Set create a directory at /tmp (For Ex. /tmp/ansiblelog and mention it as log directory in Ansible.cfg  with proper permission to the installing user id.

 

Thanks

jeromesauve
Fluorite | Level 6

I would not suggest modifiying the directories permissions or the Ansible.config directly. While you might get rid of the error message during the installation, you might also end up with a broken installation if files/directories/dependencies are not installed with the proper users/rights. Use with caution.

jeromesauve
Fluorite | Level 6

Hi,

Can you copy the command line you use to do the installation?

The explication is that ansible will run certain task as root, and others as the installation user. Therefore, you must provide Ansible with the sudo password with the switch --ask-become-pass. If you typed sudo before the command, Some file/directory that should have been created as the installation user belong to root. Therefore the install user cannot access them later in the process.

 

Correct:

ansible-playbook site.yml --ask-become-pass -vvv

 

Not correct:

 

 sudo ansible-playbook site.yml -vvv

Jérôme

 

Iyappan21
Obsidian | Level 7
@jeromesauve Thanks for the suggestion. Its worth information.
In my case, I have modified ansible log directory at ansible.cfg and deployment was successful.

Thanks,
Iyappan M S