# How to get ansible sequence number of running

**URL:** <https://forum.ansible.com/t/how-to-get-ansible-sequence-number-of-running/22910>\
**Category:** Ansible Project\
**Created:** [October 28, 2016, 7:35am UTC](https://forum.ansible.com/t/how-to-get-ansible-sequence-number-of-running/22910 "2016-10-28T07:35:39Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![harold\_T](https://avatars.discourse-cdn.com/v4/letter/h/b5e925/32.png) [@harold\_T](https://forum.ansible.com/u/harold_T)\
**Post date:** [October 28, 2016, 7:35am UTC](https://forum.ansible.com/t/how-to-get-ansible-sequence-number-of-running/22910/1 "2016-10-28T07:35:39Z")

</div>

Here is run.yml and rozofs.yml, I want to get the sequence number of each running.

there is 4 IP address, 90,91,92,93, I want to know where I can get 1,2,3,4 from each running. I am use "echo " to put each IP address, I want to the sequence number too.

```auto
$ run.yml

---
- hosts: "{{ store }}"
  remote_user: root
  vars_files:
    - /vars/rozofs.yml
  tasks:
    - name: mount fs
      command: echo "{{ inventory_hostname }}" >> /root/temp.sh
    - name: sequence number
      command: echo ??? >> /root/temp.sh 

```

```auto

```

```auto
$ rozofs.yml
---
store: 192.168.2.90 192.168.2.91 192.168.2.92 192.168.2.93

$ temp.sh
192.168.2.90
1

$ temp.sh
192.168.2.93
4

```
