<p dir="auto">$ ansible --version<br>
ansible 1.0</p>
<p dir="auto">RHEL: Red Hat Enterprise Linux Server release 6.3 (Santiago)<br>
$ uname -r<br>
2.6.32-220.4.2.el6.x86_64</p>
<p dir="auto">Trying to install a rpm using yum and it returning the below although the rpm is not installed on that host :<br>
g4t3773g | success &gt;&gt; {<br>
"changed": false,<br>
"msg": "",<br>
"rc": 0,<br>
"results": [<br>
"All packages providing monit are up to date"<br>
]<br>
}</p>
<p dir="auto">[stoflet@g2t1119g wildcat]$ ansible g4t3773g -s -m yum -a "name=monit enablerepo=RedHat-6Server-x86_64-Fedora-EPEL  state=latest" -vvvv<br>
 ESTABLISH CONNECTION FOR USER: stoflet on PORT 22 TO g4t3773g<br>
 EXEC /bin/sh -c 'mkdir -p $HOME/.ansible/tmp/ansible-1359420393.49-231135382620037 &amp;&amp; chmod a+rx $HOME/.ansible/tmp/ansible-1359420393.49-231135382620037 &amp;&amp; echo $HOME/.ansible/tmp/ansible-1359420393.49-231135382620037'<br>
 REMOTE_MODULE yum name=monit enablerepo=RedHat-6Server-x86_64-Fedora-EPEL  state=latest<br>
 PUT /tmp/tmpJlTD58 TO /home/stoflet/.ansible/tmp/ansible-1359420393.49-231135382620037/yum<br>
 EXEC /bin/sh -c 'sudo -k &amp;&amp; sudo -S -p "[sudo via ansible, key=jnnoqesjxwyjnodrurispgexkogskxha] password: " -u root /bin/sh -c '"'"'/usr/bin/python -tt /home/stoflet/.ansible/tmp/ansible-1359420393.49-231135382620037/yum; rm -rf /home/stoflet/.ansible/tmp/ansible-1359420393.49-231135382620037/ &gt;/dev/null 2&gt;&amp;1'"'"''<br>
g4t3773g | success &gt;&gt; {<br>
"changed": false,<br>
"msg": "",<br>
"rc": 0,<br>
"results": [<br>
"All packages providing monit are up to date"<br>
]<br>
}</p>
<p dir="auto">Tried from boh command line (above) and playbook (below). Same thing:<br>
....<br>
tasks:</p>
<ul dir="auto">
<li>name: install HPIT EPEL repo<br>
action: yum pkg=hpit-yum-epel-repo state=latest</li>
<li>name: install mongodb-server from EPEL repo<br>
action: yum pkg=mongodb-server state=latest enablerepo=RedHat-6Server-x86_64-Fedora-EPEL<br>
...</li>
</ul>
<p dir="auto">This is occurring with other pkgs when I use enablerepo (e.g. monit) too.</p>
<p dir="auto">I ultimately got it to work on a test host using<br>
action: shell /usr/bin/yum install -y --enablerepo=<em>EPEL</em> mongodb-server<br>
from a playbook or this on the cmdline</p>
<p dir="auto">ansible g4t3773g -s -m yum -a "name=mongodb-server enablerepo=<em>EPEL</em>  state=latest"</p>
<p dir="auto">Note: I was tailing /var/log/yum.conf. Nothing was added when using the yum module and enablerepo.</p>
<p dir="auto">2 roles with the same handler named assigned to host, only 1 handler will be executed.</p>
<p dir="auto">I bisected commits, and found that the problem commit is:</p>
<p dir="auto"><a class="commit-link" data-hovercard-type="commit" data-hovercard-url="https://github.com/ansible/ansible/commit/f081c68a656488e79255eb6865b930cf56c791a9/hovercard" href="https://github.com/ansible/ansible/commit/f081c68a656488e79255eb6865b930cf56c791a9"><tt>f081c68</tt></a></p>
<p dir="auto">Here's my reproducer:</p>
<p dir="auto"><a href="https://github.com/jsmartin/test-ansible.git">https://github.com/jsmartin/test-ansible.git</a></p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="ansible-playbook --version
ansible-playbook 1.4 (devel 6dd81f25d9) last updated 2013/11/12 18:50:22 (GMT -400)


PLAY [localhost] ************************************************************** 

GATHERING FACTS *************************************************************** 
ok: [127.0.0.1]

TASK: [a | test role a echo] ************************************************** 
changed: [127.0.0.1] =&gt; {&quot;changed&quot;: true, &quot;cmd&quot;: [&quot;echo&quot;, &quot;role a&quot;], &quot;delta&quot;: &quot;0:00:00.004943&quot;, &quot;end&quot;: &quot;2013-11-12 18:55:26.645837&quot;, &quot;item&quot;: &quot;&quot;, &quot;rc&quot;: 0, &quot;start&quot;: &quot;2013-11-12 18:55:26.640894&quot;, &quot;stderr&quot;: &quot;&quot;, &quot;stdout&quot;: &quot;role a&quot;}

TASK: [b | test role b echo] ************************************************** 
changed: [127.0.0.1] =&gt; {&quot;changed&quot;: true, &quot;cmd&quot;: [&quot;echo&quot;, &quot;role b&quot;], &quot;delta&quot;: &quot;0:00:00.003273&quot;, &quot;end&quot;: &quot;2013-11-12 18:55:26.747306&quot;, &quot;item&quot;: &quot;&quot;, &quot;rc&quot;: 0, &quot;start&quot;: &quot;2013-11-12 18:55:26.744033&quot;, &quot;stderr&quot;: &quot;&quot;, &quot;stdout&quot;: &quot;role b&quot;}

NOTIFIED: [a | myhandler] ***************************************************** 
changed: [127.0.0.1] =&gt; {&quot;changed&quot;: true, &quot;cmd&quot;: [&quot;echo&quot;, &quot;handler for role A activated&quot;], &quot;delta&quot;: &quot;0:00:00.003456&quot;, &quot;end&quot;: &quot;2013-11-12 18:55:26.849426&quot;, &quot;item&quot;: &quot;&quot;, &quot;rc&quot;: 0, &quot;start&quot;: &quot;2013-11-12 18:55:26.845970&quot;, &quot;stderr&quot;: &quot;&quot;, &quot;stdout&quot;: &quot;handler for role A activated&quot;}

PLAY RECAP ******************************************************************** 
127.0.0.1                  : ok=4    changed=3    unreachable=0    failed=0  "><pre class="notranslate"><code class="notranslate">ansible-playbook --version
ansible-playbook 1.4 (devel 6dd81f25d9) last updated 2013/11/12 18:50:22 (GMT -400)


PLAY [localhost] ************************************************************** 

GATHERING FACTS *************************************************************** 
ok: [127.0.0.1]

TASK: [a | test role a echo] ************************************************** 
changed: [127.0.0.1] =&gt; {"changed": true, "cmd": ["echo", "role a"], "delta": "0:00:00.004943", "end": "2013-11-12 18:55:26.645837", "item": "", "rc": 0, "start": "2013-11-12 18:55:26.640894", "stderr": "", "stdout": "role a"}

TASK: [b | test role b echo] ************************************************** 
changed: [127.0.0.1] =&gt; {"changed": true, "cmd": ["echo", "role b"], "delta": "0:00:00.003273", "end": "2013-11-12 18:55:26.747306", "item": "", "rc": 0, "start": "2013-11-12 18:55:26.744033", "stderr": "", "stdout": "role b"}

NOTIFIED: [a | myhandler] ***************************************************** 
changed: [127.0.0.1] =&gt; {"changed": true, "cmd": ["echo", "handler for role A activated"], "delta": "0:00:00.003456", "end": "2013-11-12 18:55:26.849426", "item": "", "rc": 0, "start": "2013-11-12 18:55:26.845970", "stderr": "", "stdout": "handler for role A activated"}

PLAY RECAP ******************************************************************** 
127.0.0.1                  : ok=4    changed=3    unreachable=0    failed=0  
</code></pre></div>
<p dir="auto">Here you can see only the handler in role "a" was activated</p>
<p dir="auto">Now let's try with 1.3.4</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="ansible-playbook --version
ansible-playbook 1.3.4
ansible-playbook -i hosts -v test.yml 

PLAY [localhost] ************************************************************** 

GATHERING FACTS *************************************************************** 
ok: [127.0.0.1]

TASK: [test role a echo] ****************************************************** 
changed: [127.0.0.1] =&gt; {&quot;changed&quot;: true, &quot;cmd&quot;: [&quot;echo&quot;, &quot;role a&quot;], &quot;delta&quot;: &quot;0:00:00.005104&quot;, &quot;end&quot;: &quot;2013-11-12 18:57:33.596077&quot;, &quot;item&quot;: &quot;&quot;, &quot;rc&quot;: 0, &quot;start&quot;: &quot;2013-11-12 18:57:33.590973&quot;, &quot;stderr&quot;: &quot;&quot;, &quot;stdout&quot;: &quot;role a&quot;}

TASK: [test role b echo] ****************************************************** 
changed: [127.0.0.1] =&gt; {&quot;changed&quot;: true, &quot;cmd&quot;: [&quot;echo&quot;, &quot;role b&quot;], &quot;delta&quot;: &quot;0:00:00.004365&quot;, &quot;end&quot;: &quot;2013-11-12 18:57:33.704722&quot;, &quot;item&quot;: &quot;&quot;, &quot;rc&quot;: 0, &quot;start&quot;: &quot;2013-11-12 18:57:33.700357&quot;, &quot;stderr&quot;: &quot;&quot;, &quot;stdout&quot;: &quot;role b&quot;}

NOTIFIED: [myhandler] ********************************************************* 
changed: [127.0.0.1] =&gt; {&quot;changed&quot;: true, &quot;cmd&quot;: [&quot;echo&quot;, &quot;handler for role A activated&quot;], &quot;delta&quot;: &quot;0:00:00.004131&quot;, &quot;end&quot;: &quot;2013-11-12 18:57:33.805843&quot;, &quot;item&quot;: &quot;&quot;, &quot;rc&quot;: 0, &quot;start&quot;: &quot;2013-11-12 18:57:33.801712&quot;, &quot;stderr&quot;: &quot;&quot;, &quot;stdout&quot;: &quot;handler for role A activated&quot;}

NOTIFIED: [myhandler] ********************************************************* 
changed: [127.0.0.1] =&gt; {&quot;changed&quot;: true, &quot;cmd&quot;: [&quot;echo&quot;, &quot;handler for role B activated&quot;], &quot;delta&quot;: &quot;0:00:00.004174&quot;, &quot;end&quot;: &quot;2013-11-12 18:57:33.910559&quot;, &quot;item&quot;: &quot;&quot;, &quot;rc&quot;: 0, &quot;start&quot;: &quot;2013-11-12 18:57:33.906385&quot;, &quot;stderr&quot;: &quot;&quot;, &quot;stdout&quot;: &quot;handler for role B activated&quot;}

PLAY RECAP ******************************************************************** 
127.0.0.1                  : ok=5    changed=4    unreachable=0    failed=0   "><pre class="notranslate"><code class="notranslate">ansible-playbook --version
ansible-playbook 1.3.4
ansible-playbook -i hosts -v test.yml 

PLAY [localhost] ************************************************************** 

GATHERING FACTS *************************************************************** 
ok: [127.0.0.1]

TASK: [test role a echo] ****************************************************** 
changed: [127.0.0.1] =&gt; {"changed": true, "cmd": ["echo", "role a"], "delta": "0:00:00.005104", "end": "2013-11-12 18:57:33.596077", "item": "", "rc": 0, "start": "2013-11-12 18:57:33.590973", "stderr": "", "stdout": "role a"}

TASK: [test role b echo] ****************************************************** 
changed: [127.0.0.1] =&gt; {"changed": true, "cmd": ["echo", "role b"], "delta": "0:00:00.004365", "end": "2013-11-12 18:57:33.704722", "item": "", "rc": 0, "start": "2013-11-12 18:57:33.700357", "stderr": "", "stdout": "role b"}

NOTIFIED: [myhandler] ********************************************************* 
changed: [127.0.0.1] =&gt; {"changed": true, "cmd": ["echo", "handler for role A activated"], "delta": "0:00:00.004131", "end": "2013-11-12 18:57:33.805843", "item": "", "rc": 0, "start": "2013-11-12 18:57:33.801712", "stderr": "", "stdout": "handler for role A activated"}

NOTIFIED: [myhandler] ********************************************************* 
changed: [127.0.0.1] =&gt; {"changed": true, "cmd": ["echo", "handler for role B activated"], "delta": "0:00:00.004174", "end": "2013-11-12 18:57:33.910559", "item": "", "rc": 0, "start": "2013-11-12 18:57:33.906385", "stderr": "", "stdout": "handler for role B activated"}

PLAY RECAP ******************************************************************** 
127.0.0.1                  : ok=5    changed=4    unreachable=0    failed=0   
</code></pre></div>
<p dir="auto">Here you can see both handlers were activated.</p>