LVM

  1. How to increase the size of LVM partition ?
    1. Use the lvextend command (lvextend -L +100M /dev/<Name of the LVM Partition> , in this example we are extending the size by 100MB.
    2. resize2fs /dev/<Name of the LVM Partition>
    3. check the size of partition using ‘df -h’ command
  1. How to reduce or shrink the size of LVM partition ?
    1. Umount the filesystem using umount command,
    2. use resize2fs command , e.g resiz2fs /dev/mapper/myvg-mylv 10G
    3. Now use the lvreduce command , e.g lvreduce -L 10G /dev/mapper/myvg-mylv