VCP – Disk space

      1 Comment on VCP – Disk space

In my next post, I’m going to install VUM (VM update manager) and it’s going to take more space than I have available on the C drive of my vCenter server.  So, what I need to do is extend the C drive of the VM.  However, there isn’t enough space on the LUN from my iSCSI server to extend it as large as I want.  So I’m going to have to fix that too.  So I’ll tackle this post in two pieces.  First, we’ll extend the data store, and second we’ll extend the disk on the Windows host.

Extending a VMFS partition
So there are a couple of options for doing this.  If the disk that the storage array presented to you has available space, you can simply extend the VMFS partition.  If it doesn’t you can add on ‘extents’ which are basically additional LUNs from the storage array.  We are going to do both so let’s start with the simple extend.

To extend a data-store, log into vCenter, go to home, and then select ‘Datastores and Datastore Clusters’.  Select the data store you’d like to extend on the left, and the click the configuration tab on the right…

image 
In the Datastore detail pane, click the properties button….

image
Examine the total capacity of the existing VMFS datastore.  We are currently at 99.75 gig.  Now, click the ‘Increase’ button…

image
Select your existing datastore from the available and click Next…

image
On the nest screen, you can see that vSphere determined that there was available free space on the LUN that could be used to expand the VMFS datastore.  If there wasn’t we’d be talking about adding an extent.  Click Next…

image 
Since we want to use all of the free space on the disk, leave the default setting and click Next…

image 
To wrap up the configuration, click Finish.  This will kick off the VMFS Expand task as well as a rescan…

image
Once these are done, the VMFS store size will show our new available size…

image
Now, if we wouldn’t have had free space on the disk to expand into, we could add an extent.  Let’s add a small 5 gig extent to the same VMFS store just as an example.  Click the properties button for the datastore again, and once again click the increase button…

image
If everything goes to plan (which is didn’t the first time around for me.  See this post) you should see the new available LUN that you are going to use as an extent.  Select it and click Next…

image 
Click Next again…

image 
Click Next again…

image 
Click Finish.  When the task wraps up, you should see your new extent in the list of available extents for that particular VMFS volume….

image

And if we close the window, we should see our new size reflects the extent being added…

image

Note, this can all be done on the fly without affecting any running VMs on the VMFS datastore.  So now that we’ve seen how to increase the size of a disk on the ESXi side, let’s increase the size of the disk on the host…

Extending an NTFS partition on a Windows host
So now that we have free space on the VMFS datastore, let’s increase the size of the disk allocated to the VM.  We started with 10 gig, so lets’ bump it up to 80.  Right click the VM, edit settings, select your hard drive, and change the size to 80 gig and hit OK to process the settings…

image

Now, let’s go look at the host side of things.  Log into Windows and go to disk management.  As we expected, the NTFS partition is still 10, but the disk now has 70 gig free…

image
The expansion of the partition is easiest handled by using ExtPart.exe.  If you’ve never used it before, google for it and download.  Right click on the unallocated space and see exactly how many megabytes are free.  In my case it was 71688 meg.  This it the output of my running the tool…

image  
And when it’s done running…

image 
I now have my 80 gig C drive.  All done…

1 thought on “VCP – Disk space

Leave a Reply

Your email address will not be published. Required fields are marked *