# ansible taking a really long time

**URL:** <https://forum.ansible.com/t/ansible-taking-a-really-long-time/34067>\
**Category:** Ansible Project\
**Tags:** rhel\
**Created:** [October 20, 2020, 9:22pm UTC](https://forum.ansible.com/t/ansible-taking-a-really-long-time/34067 "2020-10-20T21:22:32Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Mike\_Eggleston](https://avatars.discourse-cdn.com/v4/letter/m/58956e/32.png) [@Mike\_Eggleston](https://forum.ansible.com/u/Mike_Eggleston)\
**Post date:** [October 20, 2020, 9:22pm UTC](https://forum.ansible.com/t/ansible-taking-a-really-long-time/34067/1 "2020-10-20T21:22:32Z")

</div>

When I run: $ ansible all -m command -a uptime -o  
for 97 hosts (Solaris and GNU/Linux) the command (just ran) takes 31 minutes.

How can I find where the time is being spent?  
I have a custom ~/.ansible.cfg that specifies my inventory and “remote\_tmp = $HOME/.ansible/tmp” (to get around a Solaris issue).  
I have environment variables of ANSIBLE\_INVENTORY and ANSIBLE\_LOG\_PATH. I’m running this on a RHEL 7 box that is idle.

TIA

Mike

---

<div class="post-metadata">

**Author:** ![Joseph\_Alexander](https://avatars.discourse-cdn.com/v4/letter/j/6a8cbe/32.png) [@Joseph\_Alexander](https://forum.ansible.com/u/Joseph_Alexander)\
**Post date:** [October 20, 2020, 9:36pm UTC](https://forum.ansible.com/t/ansible-taking-a-really-long-time/34067/2 "2020-10-20T21:36:55Z")

</div>

two questions:

is your inventory dynamic? Is it running a script to fetch and create it each time?  
second, what about running: ansible all -m ping  
does that also take ~31 minutes to return?

---

<div class="post-metadata">

**Author:** ![Mike\_Eggleston](https://avatars.discourse-cdn.com/v4/letter/m/58956e/32.png) [@Mike\_Eggleston](https://forum.ansible.com/u/Mike_Eggleston)\
**Post date:** [October 20, 2020, 10:32pm UTC](https://forum.ansible.com/t/ansible-taking-a-really-long-time/34067/3 "2020-10-20T22:32:09Z")

</div>

Inventory is static and I’ll run the command when I back online. 🙂

Mike

---

<div class="post-metadata">

**Author:** ![Mike\_Eggleston](https://avatars.discourse-cdn.com/v4/letter/m/58956e/32.png) [@Mike\_Eggleston](https://forum.ansible.com/u/Mike_Eggleston)\
**Post date:** [October 21, 2020, 12:17pm UTC](https://forum.ansible.com/t/ansible-taking-a-really-long-time/34067/4 "2020-10-21T12:17:01Z")

</div>

This morning the command “ansible all -m ping” took 34 seconds and my “standard” command “audible all -m command -a uptime -o” took 15 seconds. Maybe it was a fluke. Thank you Joseph for answering. I’ll monitor throughout the day.

Mike
