/How to add extra space to vCenter for the upgrade

How to add extra space to vCenter for the upgrade

When we try to upgrade vCenter Appliance if we have much data to migrate from one version to another (this is from 6.5 to 6.7 or 7.0), we need to have enough space in the root partition in the source vCenter Appliance (bear in mind that the upgrade will create a new VCSA VM). If there is no space, we get an error in the upgrade.

In this How to add extra space to vCenter for the upgrade, I will explain how to add extra space to your vCenter Appliance before you start the upgrade.

This procedure needs to be done before you start your upgrade.

This is an example of what type of data will be migrated from the source vCenter.

As shown in the above image, we will need a space of at least 8Gb in the root / vCenter partition for the upgrade, which is used as a temporary folder for the data migration. And in this case, the space available is only 4.2Gb.

Login to your vCenter console and check the space.

If we continue with the migration, we will get an error almost when it finishes the upgrade.

I had this many times, so I have many examples and screenshots from several upgrades I have done.

How to add extra space to vCenter for the upgrade?

“Edit Update 20/06/2020

There were some comments from readers (in this blog post and some vExpert groups) regarding the options to extend a root partition in vCenter Appliance 6.5. So I decided to add some extra information to clarify the alternatives to extend the root partition and what other options we could have to bypass the vCenter upgrade lack of space.

So I will propose different options and not just add an NFS Shared Folder.”

The latest vCenter Appliance version I am trying to upgrade is VMware vCenter Server Appliance 6.5.0.32400 Build Number 16275158 – 28/05/2020.

  • First option:

    Use a different partition for the temp files.

Note: I could have proposed this option when I wrote the blog post, but honestly, I forgot. Even I had some screenshots of some examples I did some time ago.

Check your Appliances partitions space.

In the above example is possible to check that partition /storage/updatemgr/ for vCenter updates (or VUM) has enough space for the temporary migrations files.

The best option is to create a temp folder inside the partition and use it for the migration files.

Then in your upgrade task, use the folder you created in the /storage/updatemgr partition.

  • Second option:

In our Storage system or file server, whatever you are using to provide space, create an NFS shared folder with enough space to store the temporary files and mount in the vCenter.

After you create an NFS shared folder, login to vCenter and mount the shared folder in vCenter.

In the above commands, I also included the command dd if=/dev/zero of=file_name.txt bs=1MB count=1 to ensure that vCenter can write in the shared folder if not, the upgrade will again break.

Note: Don’t forget to create the NSF Share with proper permissions and use user/pass to mount in your vCenter.

In the upgrade process, in the step to select the type of data to migrate, select your option and then select Export Directory and add the shared folder that you just mounted.

Note: The need to mount an NFS Shared folder for your upgrade is for upgrades from vCenter Appliance 6.5/6.7 or to 7.0. The process and steps are the same. If you are upgrading from a Windows vCenter, if you don’t have space, you need to add extra space to your Windows vCenter disks.

  • Third option:

Expand the root partition or even a different partition to use for the migration files.

Edit your vCenter Appliance VM and change the size of the disk/partition you need to expand.

This is the list of disks and which partitions belong to.

You can also use the command df -h; lsblk; lsscsi to check SCSI ID and then trace which SCSI ID will show in the VM edit settings. But it is better and easier to follow the above table.

Again check your partitions and select the one you need to extend and change in the VM settings. For this case, I will expand the root partition ‘/’, which is VMK1 disk.

Note: Do not forget if the VM has any snapshots is not possible to edit the disk size. You need to remove any existing snapshots to be able to change the disk size in the settings.

After you run the VMware script that is inside of vCenter Appliance for extending the space of the LVM partition: /usr/lib/applmgmt/support/scripts/autogrow.sh

After running the command, double-check the partitions, and you should see a new size on the partition you just resized.

Note: The resizing of any partition in vCenter Appliance 6.7 or 7.0 can be done online. No need to reboot or power off the vCenter so that the resize takes place. So you can do this task and go back to the upgrade process and continue without the need to cancel or restart the upgrade process.

Final comments:

The First and Second options are for upgrades from 6.5 to 6.7 or 7.0. Works with all versions. The Third option is only supported for 6.7 and 7.0. Since extending root partition is not supported in 6.5, as we can check in the Release Notes.

After you modify the virtual machine configuration of the vCenter Server Аppliance to provide a larger disk space for expanding the root partition, an attempt to claim that additional storage fails
After resizing the disk space for the root partitioning, the storage.resize command does not extend the disk storage for the root partition but keeps it the same size. This is an expected behavior. Resizing this partition is not supported.

Some workarounds exist for expanding the root partition when using vCenter Appliance 6.5 . Besides, it is not supported. Why spend time and work to do this when we have better alternatives. Also, why spend time resizing the root partition when in the end, the vCenter Appliance will be deleted, and a new one will be created?

Also, when using the First and Second options, you do not need to reboot or cancel your Upgrade process, do the tasks when you get the warning about lack of space for the migration, and go back to the upgrade process and continue without the need to cancel.

The Third option for vCenter Appliance 6.7 or 7.0 can also be done online without the need to power to reboot or cancel the upgrade process.

Other articles in the VMware upgrades series:

Note: I Will update the links to the above articles while I will write them.

I hope this information was helpful.

Share this article if you think it is worth sharing. If you have any questions or comments, comment here or contact me on Twitter.

©2020 ProVirtualzone. All Rights Reserved
By | 2023-06-07T09:41:32+02:00 June 18th, 2020|vCenter, VMware Posts|2 Comments

About the Author:

I have over 20 years of experience in the IT industry. I have been working with Virtualization for more than 15 years (mainly VMware). I recently obtained certifications, including VCP DCV 2022, VCAP DCV Design 2023, and VCP Cloud 2023. Additionally, I have VCP6.5-DCV, VMware vSAN Specialist, vExpert vSAN, vExpert NSX, vExpert Cloud Provider for the last two years, and vExpert for the last 7 years and a old MCP. My specialties are Virtualization, Storage, and Virtual Backup. I am a Solutions Architect in the area VMware, Cloud and Backup / Storage. I am employed by ITQ, a VMware partner as a Senior Consultant. I am also a blogger and owner of the blog ProVirtualzone.com

2 Comments

  1. Souihel Ayoub 19/06/2020 at 11:06

    hello ,
    thank you , it is a great post , to the fix the space issue you can expand the disk and run the autogrowth script

    • Luciano Patrao 19/06/2020 at 13:37

      Hi Souihel,

      Yes and no. First, in vCenter 6.0/6.5 extending root partition is supported. Only in 6.7 and 7.0.
      But we can extend another partition and use it for the imported files. I will update the blog post with that option.
      But honestly, why should you extend a partition of a vCenter that it will be deleted?

Leave A Comment