Post

Getting multipath output from servers with Ansible

Simple Ansible playbook to gather and display multipath output from multiple servers defined in inventory.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
---
  - name: Run multipath -ll command
    become: true
    become_user: root
    gather_facts: yes

    tasks:
      - name: Execute multipath -ll command
        command: multipath -ll
        register: multipath_output
        changed_when: false
    
      - name: Display multipath output
        debug:
          var: multipath_output.stdout_lines
This post is licensed under CC BY 4.0 by the author.