# Multipathd is not enabling

**URL:** <https://forum.ansible.com/t/multipathd-is-not-enabling/38529>\
**Category:** Ansible Project\
**Created:** [October 18, 2023, 3:33am UTC](https://forum.ansible.com/t/multipathd-is-not-enabling/38529 "2023-10-18T03:33:48Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![Prady\_A](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/prady_a/32/4792_2.png) [@Prady\_A](https://forum.ansible.com/u/Prady_A)\
**Post date:** [October 18, 2023, 3:33am UTC](https://forum.ansible.com/t/multipathd-is-not-enabling/38529/1 "2023-10-18T03:33:48Z")

</div>

Hi All…

I ve a very 2 very basic task of enabling multipath.  
The 2 task is failing since the first one is not enabling. But in ansible job it is showing as changed but when I checked multipath service in system it is showing as Below:

Active: inactive(dead)  
Condition: start condition failed

> - ConditionPathExists=/etc/multipath.conf was not met

**Tasks**

---

<div class="post-metadata">

**Author:** ![dulhaver](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/dulhaver/32/1061_2.png) [@dulhaver](https://forum.ansible.com/u/dulhaver)\
**Post date:** [October 18, 2023, 5:08am UTC](https://forum.ansible.com/t/multipathd-is-not-enabling/38529/2 "2023-10-18T05:08:49Z")

</div>

hi,

the syntax of your TASK sems not to match the [docs for the service module](https://docs.ansible.com/ansible/latest/collections/ansible/builtin/service_module.html#ansible-collections-ansible-builtin-service-module). Would something like …

```auto
   - name: Enable service httpd, and not touch the state
     ansible.builtin.service:
       name: multipathd
       state: started
       enabled: true

... work?

```

---

<div class="post-metadata">

**Author:** ![Prady\_A](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/prady_a/32/4792_2.png) [@Prady\_A](https://forum.ansible.com/u/Prady_A)\
**Post date:** [October 18, 2023, 6:25am UTC](https://forum.ansible.com/t/multipathd-is-not-enabling/38529/3 "2023-10-18T06:25:01Z")

</div>

Thank you . Due to some old iso image the multipath is not able to enable . We have to update the iso image it seems

Thank you

---

<div class="post-metadata">

**Author:** ![Will\_McDonald](https://avatars.discourse-cdn.com/v4/letter/w/f475e1/32.png) [@Will\_McDonald](https://forum.ansible.com/u/Will_McDonald)\
**Post date:** [October 18, 2023, 9:11am UTC](https://forum.ansible.com/t/multipathd-is-not-enabling/38529/4 "2023-10-18T09:11:15Z")

</div>

This seems like a pretty glaring error:

> ConditionPathExists=/etc/multipath.conf was not met

This is likely nothing to do with Ansible. You’re installing a multipath package, enabling a service, the service is failing to start automatically because it doesn’t have any valid config. You should see the same problem if you perform the same steps manually. Figure out your manual process first, then automate it.

Either:

1. Include a templated /etc/multipath.conf config before enabling/starting the systemd service

2. Run something like mpathconf --enable to create a default config

3. Override/replace the Condition in the systemd unit file (probably a bad idea).

---

<div class="post-metadata">

**Author:** ![Prady\_A](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/prady_a/32/4792_2.png) [@Prady\_A](https://forum.ansible.com/u/Prady_A)\
**Post date:** [October 18, 2023, 5:24pm UTC](https://forum.ansible.com/t/multipathd-is-not-enabling/38529/5 "2023-10-18T17:24:10Z")

</div>

Thank you so much for your kind reply.

For temporary fix I copied the /etc/multipath.conf from other machine but eventually we need to update our ISO image to include this file.

Regards  
PD

---

<div class="post-metadata">

**Author:** ![Will\_McDonald](https://avatars.discourse-cdn.com/v4/letter/w/f475e1/32.png) [@Will\_McDonald](https://forum.ansible.com/u/Will_McDonald)\
**Post date:** [October 23, 2023, 2:25pm UTC](https://forum.ansible.com/t/multipathd-is-not-enabling/38529/6 "2023-10-23T14:25:59Z")

</div>

I’d recommend looking at having your role or playbook drop in a sensible, templated configuration personally.

Baking a static file into an ISO will almost certainly cause future pain unless you only ever deploy one hardware and storage combination with absolutely zero variation?

---

<div class="post-metadata">

**Author:** ![Prady\_A](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/prady_a/32/4792_2.png) [@Prady\_A](https://forum.ansible.com/u/Prady_A)\
**Post date:** [October 24, 2023, 11:02am UTC](https://forum.ansible.com/t/multipathd-is-not-enabling/38529/7 "2023-10-24T11:02:46Z")

</div>

Thank you for your suggestion. These code are inside our Tower placed in git.

Right now I ve no idea why they are baking a file to iso instead they could do using template. I need to dig more …

Thanks again for your help
