HowTo: Resize an EXT4-formatted Linux LVM Volume in a virtual machine

1. Resize the volume using VMWare VM-Manager. The size field is greyed out if there are any snapshots defined... you'll have
to delete them.

2. Start the virtual machine.

3. Use cfdisk to create a new logical partition in the free space of the virtual disk. Use type 8e - Linux LVM. Note: fdisk
did not see the free space on the device. The new partition is /deb/sda6 in this example.

4. REBOOT the virtual machine. In our tests the change to the partition table was not visible after exiting cfdisk.# reboot

7. Add the physical volume to the volume group found in the field 'VG Name':# vgextend mongo1 /dev/sda6 Volume group "mongo1" successfully extended

8. Now you can try to extend the existing logical volume (as named in field 'LV Name' above). If the given size increase (20GB
in this example) is more than is available in the disk group, the error message will indicate the number of blocks available:# lvextend -L +20G /dev/mapper/mongo1-root Extending logical volume root to 29,29 GiB Insufficient free space: 5120 extents needed, but only 5119 available