I have installed Ansible in Centos 7 minimal environment , using the latest version in EPEL (ansible-2.1.1.0-1.el7.noarch). I have to deal with a very strange phenomenon where the execution of a .yml configuration goes very slow, when I have to execute it for some remote SLES 11 SP3 virtual machines. It seems that for these remote virtual machines, 100sec have to be completed before the setup goes forward. I have tested the same .yml for Centos 7 remote machines, and works fine, and I have also tested in another environenment with Centos6 and SLES11 SP2 virtual machines, and they work just fine. I have tested the execution as root or non-privileged user without differences. In cases that I’m going to stop the execution in the middle, an indication like this may be written.
File “/usr/lib64/python2.7/multiprocessing/process.py”, line 258, in _bootstrap
File “/usr/lib64/python2.7/multiprocessing/process.py”, line 258, in _bootstrap
self.run()
File “/usr/lib/python2.7/site-packages/ansible/executor/process/worker.py”, line 117, in run
self.run()
File “/usr/lib/python2.7/site-packages/ansible/executor/process/worker.py”, line 117, in run
self._rslt_q
self._rslt_q
File “/usr/lib/python2.7/site-packages/ansible/executor/task_executor.py”, line 124, in run
File “/usr/lib/python2.7/site-packages/ansible/executor/task_executor.py”, line 124, in run
I have captured also some traces through tcpdump where the connection between two nodes is being seen and 100seconds where the remote nodes, are waiting to respond are evident. Is there any idea ?!!!
I managed to investigate the issue. The problem was that all servers with slow performance have DNS server configured in /etc/resolv.conf. When DNS server search is disabled then node setup is ok. Now, I have to find a solution about how we can overcome this problem with DNS search.
Τη Δευτέρα, 10 Οκτωβρίου 2016 - 6:23:41 μ.μ. UTC+3, ο χρήστης Anas Theo έγραψε:
As I have described in the previous comment, the problem was due to DNS searching for a DNS server that has not been accessible from the hosts. For that reason, I have tried to setup for these hosts, only the variable that I was going to use, using filter options like “filter=ansible_hostname” . However, it seems that the search time is the same. Is there any option to get the facts I want independently from the rest of them, in order to boost the performance of setup. Thanks for your help.
Τη Δευτέρα, 10 Οκτωβρίου 2016 - 6:23:41 μ.μ. UTC+3, ο χρήστης Anas Theo έγραψε: