# Lvscan (view LV partition)
ACTIVE '/dev/volgroup/lv_root ' [2.5 GiB] Inherit
ACTIVE '/dev/volgroup/lv_swap ' [2 Gib] Inherit
# Lvdisplay (show LV details)
# Lvreduce-l -1000m/dev/volgroup/lv_swap (reduce the Lv_swap partition size by 1000M.) Swap partition 1G enough)
# Lvextend-l +920m/dev/volgroup/lv_root (Expand the Lv_root partition 992M, here to explain, I originally released 1000M space, but check the rest of the space found only 992M, So I added this number, for specific reasons.
It's just changed the size of the Lv_root partition, but the root file system is still 2.5G with df-h, and then you need to resize the file system. You need to uninstall the partition you want to adjust first. Because I am the root directory cannot uninstall. I started the system with the ISO CD and entered the following command on the live system:
# Resize2fs/dev/volgroup/lv_root (make the increased logical volume take effect immediately)
# Lvscan (show adjusted LV situation)
ACTIVE '/dev/volgroup/lv_root ' [3.53 GiB] Inherit
ACTIVE '/dev/volgroup/lv_swap ' [992.00 MiB] Inherit
# Df-h (Display the adjusted file system)
FileSystem Size Used Avail use% mounted on
/dev/mapper/volgroup-lv_root 3.5G 2.4G 1.1G 70%/