Update role dependencies

This commit is contained in:
2024-02-08 15:55:01 -05:00
parent e09a7f7d45
commit bb21e8d5c6
507 changed files with 1270 additions and 28219 deletions

View File

@@ -2,9 +2,19 @@
the_root_vgname='{{ ansible_lvm.lvs[the_root_lvname].vg | default('vg00') }}'
the_root_lvname='{{ the_root_lvname | default('root') }}'
error=$(vgdisplay $the_root_vgname 2>&1 >/dev/null)
device_name=$(echo "$error" | grep -o '/dev/[^[:space:]]*')
if [[ -n "$device_name" ]]; then
# need to remove the lvmdevice and add it back
lvmdevices --yes --deldev $device_name
lvmdevices --yes --adddev $device_name
fi
the_root_pvname=$(vgdisplay -v $the_root_vgname 2> /dev/null | awk '/PV Name/ {print $3}')
the_root_pv_partnum=$(echo $the_root_pvname | grep -o '[0-9]$')
the_root_pv_device=$(echo $the_root_pvname | grep -o '.*[^0-9]')
the_root_pv_device="/dev/$(lsblk -ndo PKNAME $the_root_pvname)"
the_root_mount_point=$(lsblk -l -o NAME,MOUNTPOINT | grep $the_root_vgname-$the_root_lvname | awk '{print $2}')
/usr/bin/growpart $the_root_pv_device $the_root_pv_partnum