Hello Team,
I am new in Ansible , I have playbook task in which it will update mysql DB Record & complete.
but its showing me blow error , I am not sure what it could be …
“rc”: 2,
“msg”: “[Errno 2] No such file or directory”
ENVIRONMENT
AWX version: 1.0.3.29
AWX install method: , docker on linux .
Ansible version: Ansible 2.4.3.0
Operating System:-CentOS Linux release 7.4.1708 (Core)
do I need to install any additional packges inside docker image , if yes how I do that …
Can you run with a higher verbosity set on the job template? Also this mailing list is for AWX-specific issues, you would probably have more prompt responses if you ask in the ansible irc channel
ansible-playbook 2.4.3.0
config file = /etc/ansible/ansible.cfg
configured module search path = [u’/var/lib/awx/.ansible/plugins/modules’, u’/usr/share/ansible/plugins/modules’]
ansible python module location = /usr/lib/python2.7/site-packages/ansible
executable location = /usr/bin/ansible-playbook
python version = 2.7.5 (default, Aug 4 2017, 00:39:18) [GCC 4.8.5 20150623 (Red Hat 4.8.5-16)]
Using /etc/ansible/ansible.cfg as config file
PLAYBOOK: hem.yml **************************************************************
1 plays in hem.yml
PLAY [127.0.0.1] ***************************************************************
TASK [Gathering Facts] *********************************************************
ok: [127.0.0.1]
META: ran handlers
TASK [Update My Sql database] **************************************************
task path: /var/lib/awx/projects/vmware/hem.yml:7
fatal: [127.0.0.1]: FAILED! => {“changed”: false, “cmd”: “mysql -h (mydbhost) -u root -p(dbpass) SAS -e 'UPDATE abc SET status = '\”‘\“‘Completed’\”’\“’ WHERE Name = '\”‘\“‘TEST5’\”’\“‘;’”, “msg”: “[Errno 2] No such file or directory”, “rc”: 2}
PLAY RECAP *********************************************************************
127.0.0.1 : ok=1 changed=0 unreachable=0 failed=1
Seems to me like probably a syntax error of some sort with your MySQL command. Since you are running using the cmd module from local host, that’s just like running a command on the command line. I would debug by running the MySQL command from the command line and seeing if you get the same sort of errors. Go from there, googling the error messages you are getting with “mysql” and seeing what sorts of similar things people have ran into and what they’ve done to fix.
I am installing python required packages but i get errors regarding installation failure. Do you have any reference docs to install the py packages in container and make the changes permanent? It would really be helpful.