Hello there!, i'm khan, and thankyou for visiting this Site, alright lets straight to the point, In this post i want to share how to expand or extend root LVM partition without restarting VM or OS.


Prerequesities

Make sure that program named "parted" is installed, or you can installing it by using this command


Expand root using parted

please make sure you are logged-in as root, and run this command to see your unallocated disk


and make sure your root partition using lvs command


so from 2 data above we know that my root volume are located in /dev/sda3 and in VG Centos, LV root, and the unallocated storage are still in /dev/sda, and we need to move that to /dev/sda3 using this command


then we need to update partition fstab, run this command for updating /etc/fstab


Update PV size (/dev/sda3) using this command


then finally extend the root volume using this command


run lsblk again to verify that success