- name: Create zpool ansible.builtin.command: cmd: zpool create {{ zpool_name }} {{ zpool_dev }} creates: /{{ zpool_name }} - name: Check if the folder exists ansible.builtin.stat: path: /usr/share/ganeti/extstorage/zfs register: folder_check - name: Reinstall lvm2 if ZFS extstorage is installed ansible.builtin.command: cmd: apt reinstall lvm2 register: lvm2_reinstall_result changed_when: lvm2_reinstall_result.rc == 0 when: folder_check.stat.exists - name: Create LVM vg community.general.lvg: vg: "{{ vg_name }}" pvs: "{{ pvs }}"