How to Increase the size of a Linux LVM by expanding the virtual machine disk
Identifying the partition type As this method focuses on working with LVM, we will first confirm that our partition type is actually Linux LVM by running the below command. fdisk -l As you can see in the above image /dev/sda5 is listed as “Linux LVM” and it has the ID of 8e. The 8e hex code shows that it is a Linux LVM, while 83 shows a Linux native partition. Now that we have confirmed we are working with an LVM we can continue. For increasing the size of a Linux native partition (hex code 83) see this article. Below is the disk information showing that our initial setup only has the one 20gb disk currently, which is under the logical volume named /dev/mapper/Mega-root – this is what we will be expanding with the new disk. Note that /dev/mapper/Mega-root is the volume made up from /dev/sda5 currently – this is what we will be expanding. Increasing the virtual hard disk First off we increase the allocated disk space on the virtual machine itself. This is done by r...