How to Increase Disk Space on a VM When Using VMware, Ubuntu, and LVM

You’ll need the GParted ISO before you start.

    1. Delete any snapshots (this allows you to increase the disk size).
    2. Edit virtual machine settings, then increase the disk size.
    3. Create a snapshot in case anything goes wrong.
    4. Boot GParted ISO.
    5. Resize the partition related to the LVM volume.
    6. Save your changes and then boot into the VM.
    7. Type the following command in the terminal:
sudo lvdisplay
    1. Note the LV Name (logical volume name).
    2. Type the following command in the terminal:
sudo pvdisplay
    1. Note the number of Free PE (free physical extents).
    2. Run the following command (if you want to use all available PE):
sudo lvextend --resizefs --extents <free_pe> <lv_name>

Don’t forget to delete the snapshot when you’re done!