[AWX] Ansible Timeout Error Problem
Posted On 2020-05-31
- OS Version: RHEL 7.8
- Target Instance Ansible Version: 2.4.7
- AWX Ansible Version: 2.9.9
When you run ansible and want to gather facts or execute some command but got this error message like below:
fatal: [default]: FAILED! => {"failed": true, "msg": "ERROR! Timeout (12s) waiting for privilege escalation prompt: "}
There are some possible situation you will need to check.
- Linux Firewall Daemon (firewalls or iptables....etc)
- Hosts Firewall Rule (Fortigate, Checkpoint, Sophos....etc)
- SELinux is permissive or enable (RHEL Family)
- Ansible connection timeout config
Ansible Connection Timeout Config
There are some timeout config may need to change, because some of your network environment are not very well.
So you will need to change it, most config default is 10 second.
You can edit to /etc/ansible/ansible.cfg
or add your own playbook's config.
[defaults] timeout = 30 [persistent_connection ] command_timeout = 30 connect_timeout = 30