3 if [ ! -x /sbin
/lvm
]; then
4 echo "ERROR: /sbin/lvm not exists or executable"
8 echo "Configuring LVM volumes ..."
10 export LVM_SYSTEM_DIR
=/var
/tmp
/lvm2
11 [ -d "$LVM_SYSTEM_DIR" ] || mkdir
$LVM_SYSTEM_DIR
13 # Scan for volume groups
14 /sbin
/lvm vgscan
--mknodes --ignorelockingfailure &> /dev
/null
16 # Change volume availability to yes
17 /sbin
/lvm vgchange
--ignorelockingfailure -a y
> /dev
/null
19 # Get a list of volumes and display it
20 LV_LIST
=$
( /sbin
/lvm vgdisplay
-C -o vg_name
--noheadings 2> /dev
/null
)
21 echo " Activated Volume Groups: $LV_LIST"