Manage disk groups and volumes

vgs - List volume groups
vgdisplay vg00 - Show details of vg00

lvs - List all logical volumes
lvdisplay /dev/vg01/lv_home - Show details of lv_home logical volume 
lvremove /dev/vg01/lv_home - Remove lv_home logical volume

lvreduce -l -4GB /dev/vg01/lv_home - Shrink by 4GB

Extend a filesystem

lvextend -L10GB /dev/vg01/lv_home    [extend TO 10GB]
lvextend -L+10GB /dev/vg01/lv_home    [extend BY 10GB]
resize2fs /dev/vg01/lv_home

Easier way to extend a filesystem !! Note: this will extend the LV and the FS

lvextend -r /dev/vg01/lv_home -L+10GB
  • linux/logical_volume_manager.txt
  • Last modified: 2020/12/10 13:23
  • by preb