Expanding Vsphere Replicated Disk

Posted on 2016-07-27
Last Modified: 2016-07-27
I have a VM with a disk that I need to expand. This VM is replicated via vsphere replication.

I disabled replication for the disk in question at the production site.
Expanded the disk in vmware and windows.
SSH'd to the DR site and navigated to the folder that contains the replicated VM.

I then ran the command vmkfstools -X 25G diablo_11-flat.vmdk

I received an error message: Failed to extend disk :  the file specified is not a virtual disk (15)

I'm thinking maybe I chose the wrong file?

This is a LS of the volume directory for that VM
/vmfs/volumes/503d564e-45450988-c9b5-ac162d79e741/Diablo # ls -l
total 241657872
-rw-------    1 root     root     64424509440 Jul 27 18:51 Diablo-flat.vmdk
-rw-------    1 root     root           588 Jul 27 18:51 Diablo.vmdk
-rw-------    1 root     root     16106127360 Jun 23 13:33 Diablo_11-flat.vmdk
-rw-------    1 root     root           587 Jun 23 16:47 Diablo_11.vmdk
-rw-------    1 root     root     64424509440 Jul 27 18:50 Diablo_12-flat.vmdk
-rw-------    1 root     root           591 Jul 27 18:50 Diablo_12.vmdk
-rw-------    1 root     root     16106127360 Jul 27 18:50 Diablo_21-flat.vmdk
-rw-------    1 root     root           587 Jul 27 18:50 Diablo_21.vmdk
-rw-------    1 root     root     64424509440 Jul 27 18:54 Diablo_8-flat.vmdk
-rw-------    1 root     root           587 Jul 27 18:51 Diablo_8.vmdk
-rw-------    1 root     root          8684 Jun 23 13:32 hbrcfg.GID-667b2083-269f-402c-88f2-30609c51e00d.7544.nvram.22629
-rw-------    1 root     root          6224 Jun 23 13:32 hbrcfg.GID-667b2083-269f-402c-88f2-30609c51e00d.7544.vmx.22627
-rw-------    1 root     root           261 Jun 23 13:32 hbrcfg.GID-667b2083-269f-402c-88f2-30609c51e00d.7544.vmxf.22628
-rw-------    1 root     root          8684 Jul 27 16:02 hbrcfg.GID-667b2083-269f-402c-88f2-30609c51e00d.8836.nvram.26502
-rw-------    1 root     root          6189 Jul 27 16:02 hbrcfg.GID-667b2083-269f-402c-88f2-30609c51e00d.8836.vmx.26500
-rw-------    1 root     root           261 Jul 27 16:02 hbrcfg.GID-667b2083-269f-402c-88f2-30609c51e00d.8836.vmxf.26501
-rw-------    1 root     root        126976 Jul 27 16:02 hbrdisk.RDID-1c29e6b2-a6ae-4fb2-9a32-1ed22b378503.24214.86199836528437-delta.vmdk
-rw-------    1 root     root           376 Jul 27 18:50 hbrdisk.RDID-1c29e6b2-a6ae-4fb2-9a32-1ed22b378503.24214.86199836528437.vmdk
-rw-------    1 root     root         32768 Jul 27 16:02 hbrdisk.RDID-1e270529-db88-48ed-88f9-78510dcf552b.24215.36769388958666-delta.vmdk
-rw-------    1 root     root           375 Jul 27 18:50 hbrdisk.RDID-1e270529-db88-48ed-88f9-78510dcf552b.24215.36769388958666.vmdk
-rw-------    1 root     root     9445605376 Jul 27 16:04 hbrdisk.RDID-35e24449-9099-4bf6-9522-58154c8bc563.20722.122185878678401-delta.vmdk
-rw-------    1 root     root           376 Jul 27 16:04 hbrdisk.RDID-35e24449-9099-4bf6-9522-58154c8bc563.20722.122185878678401.vmdk
-rw-------    1 root     root         32768 Jul 27 16:03 hbrdisk.RDID-35e24449-9099-4bf6-9522-58154c8bc563.24218.143179486828614-delta.vmdk
-rw-------    1 root     root           438 Jul 27 16:04 hbrdisk.RDID-35e24449-9099-4bf6-9522-58154c8bc563.24218.143179486828614.vmdk
-rw-------    1 root     root     12515930112 Jul 27 16:04 hbrdisk.RDID-76359cc2-ef94-4d2e-adf6-828fe5d4a5b5.20721.32971337393641-delta.vmdk
-rw-------    1 root     root           375 Jul 27 16:04 hbrdisk.RDID-76359cc2-ef94-4d2e-adf6-828fe5d4a5b5.20721.32971337393641.vmdk
-rw-------    1 root     root        126976 Jul 27 16:03 hbrdisk.RDID-76359cc2-ef94-4d2e-adf6-828fe5d4a5b5.24217.9321336014237-delta.vmdk
-rw-------    1 root     root           436 Jul 27 16:04 hbrdisk.RDID-76359cc2-ef94-4d2e-adf6-828fe5d4a5b5.24217.9321336014237.vmdk
-rw-------    1 root     root        126976 Jul 27 16:03 hbrdisk.RDID-bec2e8ef-cc0f-4d85-916b-cbbf1f129a39.24216.5990402247669-delta.vmdk
-rw-------    1 root     root           372 Jul 27 18:51 hbrdisk.RDID-bec2e8ef-cc0f-4d85-916b-cbbf1f129a39.24216.5990402247669.vmdk
-rw-------    1 root     root         12882 Jul 27 16:04 hbrgrp.GID-667b2083-269f-402c-88f2-30609c51e00d.txt

Open in new window

Specifically I want to expand the Diablo_11 VMDK and I chose the -flat version but maybe I should of chose the diablo_11.vmdk file instead?

I went with the -flat because it was the larger file and I assumed that was my actual disk, but perhaps my logic was flawed and before I continue wanted to see if anyone here can clarify.
Question by:themightydude
  • 2
LVL 119

Accepted Solution

Andrew Hancock (VMware vExpert / EE MVE^2) earned 500 total points
ID: 41731898
just specify the disk name, which is Diablo_11.vmdk and make sure it's case correct.


 vmkfstools -X 25g Diablo_11.vmdk

Open in new window

and remember the VM must be off, and the command is extend by Xg.

For example, to extend a 25g virtual disk by 1g, enter: vmkfstools -X 26g disk name.

This can be done from the GUI, and once done, you will need to expand the OS partition within the VM. This command does not perform or expand any functions in the VM.

HOW TO:  Resize a VMware (VMDK) Virtual Disk

Author Comment

ID: 41731933
Thanks Andrew.

I just wasn't sure about the -flat vs the non -flat file. To me I would think I would grow the -flat since it's the larger file, but I guess in this case since it's a replicated VM the smaller diablo_11.vmdk file is the real file.
LVL 119
ID: 41731948
the descriptor is always the file you manipulate, because it contains the disk geometry.

the flat file is the raw data.

if you are interested you can read this article, and ALL the comments, about the descriptor file and disk geometry.

HOW TO: Shrink a VMware Virtual Machine Disk (VMDK) in 15 minutes

Featured Post

Courses: Start Training Online With Pros, Today

Brush up on the basics or master the advanced techniques required to earn essential industry certifications, with Courses. Enroll in a course and start learning today. Training topics range from Android App Dev to the Xen Virtualization Platform.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

This article will show you how to create an ISO CD-ROM/DVD-ROM image (*.iso), and MD5 checksum signature, for use with VMware vSphere Hypervisor 6.5 (ESXi 6.5). It's a good idea to compare checksums, because many installations fail because of a corr…
In this article, I will show you HOW TO: Install VMware Tools for Windows on a VMware Windows virtual machine on a VMware vSphere Hypervisor 6.5 (ESXi 6.5) Host Server, using the VMware Host Client. The virtual machine has Windows Server 2016 instal…
Teach the user how to use vSphere Update Manager to update the VMware Tools and virtual machine hardware version Open vSphere Client: Review manual processes for updating VMware Tools and virtual hardware versions: Create a new baseline group in vSp…
This video shows you how easy it is to boot from ISO images for virtual machines with the ISO images stored on a local datastore on the ESXi host.

785 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question