# How to measure the time a task is taking to complete

**URL:** <https://forum.ansible.com/t/how-to-measure-the-time-a-task-is-taking-to-complete/26557>\
**Category:** Ansible Project\
**Created:** [January 24, 2018, 4:38pm UTC](https://forum.ansible.com/t/how-to-measure-the-time-a-task-is-taking-to-complete/26557 "2018-01-24T16:38:02Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Narahari\_Lakshminara](https://avatars.discourse-cdn.com/v4/letter/n/ad7895/32.png) [@Narahari\_Lakshminara](https://forum.ansible.com/u/Narahari_Lakshminara)\
**Post date:** [January 24, 2018, 4:38pm UTC](https://forum.ansible.com/t/how-to-measure-the-time-a-task-is-taking-to-complete/26557/1 "2018-01-24T16:38:02Z")

</div>

Friends:

Is there a way to measure the amount of time it takes to run task so I can get an idea how much time we are spending to deploy packages ?

-N

---

<div class="post-metadata">

**Author:** ![Guillaume\_Core](https://avatars.discourse-cdn.com/v4/letter/g/90db22/32.png) [@Guillaume\_Core](https://forum.ansible.com/u/Guillaume_Core)\
**Post date:** [January 24, 2018, 4:45pm UTC](https://forum.ansible.com/t/how-to-measure-the-time-a-task-is-taking-to-complete/26557/2 "2018-01-24T16:45:00Z")

</div>

There is [https://github.com/jlafon/ansible-profile](https://github.com/jlafon/ansible-profile)

just put

```auto
callback_whitelist = profile_tasks

```

```auto
in you ansible.cfg

```

---

<div class="post-metadata">

**Author:** ![Kai\_Stian\_Olstad](https://avatars.discourse-cdn.com/v4/letter/k/e19adc/32.png) [@Kai\_Stian\_Olstad](https://forum.ansible.com/u/Kai_Stian_Olstad)\
**Post date:** [January 24, 2018, 4:45pm UTC](https://forum.ansible.com/t/how-to-measure-the-time-a-task-is-taking-to-complete/26557/3 "2018-01-24T16:45:04Z")

</div>

You could try the callback plugin profile\_tasks

ANSIBLE\_STDOUT\_CALLBACK=profile\_tasks ansible-playbook \<playbook\>

---

<div class="post-metadata">

**Author:** ![lpescatore](https://avatars.discourse-cdn.com/v4/letter/l/ccd318/32.png) [@lpescatore](https://forum.ansible.com/u/lpescatore)\
**Post date:** [January 24, 2018, 5:31pm UTC](https://forum.ansible.com/t/how-to-measure-the-time-a-task-is-taking-to-complete/26557/4 "2018-01-24T17:31:23Z")

</div>

What I do is run the -vvvv option on my play and note the start time.
