2 - name: install lvm2 external package when lvm backend enabled
6 - name: copy opensds lvm backend file if specify lvm backend
8 src: ../../../group_vars/lvm/lvm.yaml
9 dest: "{{ lvm_config_path }}"
11 - name: check if physical volume existed
12 shell: pvdisplay {{ pv_device }}
16 - name: create a physical volume
17 shell: pvcreate {{ pv_device }}
18 when: pv_existed is undefined or pv_existed.rc != 0
20 - name: check if volume group existed
21 shell: vgdisplay {{ vg_name }}
25 - name: create a volume group
26 shell: vgcreate {{ vg_name }} {{ pv_device }}
27 when: vg_existed is undefined or vg_existed.rc != 0