- First, we unmount.
# sudo umount /dev/vg_blah/lv_blah
- set active:
vgchange -ay
- Check the file system.
# sudo e2fsck -f /dev/vg_blah/lv_blah
- shrink ext4:
resize2fs -p /dev/VolGrp000/root 10G
- Resize the file system and the logical volume. Doing this in one step can avoid mistakes which cause dataloss. (Note lvreduce parameter
-L
interpretsG
as 2^30 bytes andg
as 10^9 bytes.)
# sudo lvreduce --resizefs -L 9G /dev/vg_blah/lv_blah
- pvmove /dev/hdb
- (optional) Remove a physical drive from the volume group if desired (if you now have an unused drive).
# sudo vgreduce vg_blah /dev/sdxy