Resizing the LCM Volume group on SDDC Manager

One of the users of the VLC (VCF Lab Constructor) had an issue with drive space when attempting to upgrade from VCF 3.9 -> 3.9.1. This has been a problem in previous releases at times as well, so I thought it’d be a good opportunity to post about it. That and I don’t post nearly as often as I want to!

SDDC Manager uses LVM for several of it’s critical mount points. Coupled with the EXT4 filesystem this allows those mounts to be very flexible and non-disruptive when increasing their size.

For starters, lets take a look at how the disks are laid out in the SDDC Manager. At the “VM” level there are 4 VMDKs that are attached to the VM.

Note the SCSI addresses above.

Then we can look at how these map into the OS.

SSH into SDDC Manager as the vcf user and “su -” to root. Then enter the command:


Looking at the SCSI addresses in the vSphere UI and the SSH session we can easily determine which disk is what. All disks are on SCSI adapter “2” [host2], and each have a different target, 1-3.

At the SCSI level
At the block device level

Above, we can see that there are several LVM volumes and in a bit, we’re going to expand the “lcmmount_vg-nfs–mount” LVM.

After determining what LVM to expand, in this case we’re choosing the lcmmount_vg, add a disk to the SDDC Manager VM using the vCenter UI, for the example let’s add a 250GB thin provisioned disk.

Add disk to SDDC Manager

Next, we need to rescan the SCSI bus so the OS can pick up the new drive we just added. Below you can see a new 250GB disk has shown up with the name SDE. Prior we determined that the SCSI address for the HBA The command for rescanning the SCSI bus is:

echo "- - -" > /sys/class/scsi_host/host2/scan

Once the disk has been added and is recognized by the OS we can initialize a physical volume on it that can then be used by LVM.

pvcreate /dev/sde 

Now that our physical volume is created, we can add it to the Volume group. We already know the name of disk and the Volume group we want to extend, “lcmmount_vg”.

vgextend lcmmount_vg /dev/sde

We’ll also need to determine the Free PE after we add the physical volume. “Free PE” indicates the free physical extents in the volume group, this is needed it to tell the Logical Volume how much space we’re going to add.

vgdisplay lcmmount_vg

We only have one more piece of information to gather and then we can extend our Logical volume. We need to know what the path of this Volume group is. For that we can use the lvdisplay utility.

lvdisplay lcmmount_vg

Now that we have the path, it’s time for the final command we need to run! This command will extend the Logical Volume and resize the filesystem. We are going to use the lvextend command to accomplish this. The switches used are “-r” which tells lvextend to resize the filesystem after it’s completed adding the disk to the Volume group. The “-l +63999” tells lvextend then number of physical extents we’d like to add.

lvextend -r -l +63999 /dev/lcmmount_vg/nfs-mount

Finally, we can check to ensure that everything went ok by using the lsblk utility.

Thank you for checking out this blog, I hope it helps!

Here is a YouTube video I recorded of a very similar process. However, there are actually less steps in the blog entry, as well as the fact that you don’t even have to reboot!