VMware Communities
fgl
Enthusiast
Enthusiast

Un pre-allocate hard disk?

I have a vm with a 100GB pre-allocated hard disk that I like to shrink down to 20GB and change to a non pre-allocate disk. What is the best way to do this? I've tried the vmware-vdiskmanager but can't seem to figure out the right combination of switches it either tells me I can't do this or that the argument is missing or incorrect.

0 Kudos
6 Replies
Peter_vm
Immortal
Immortal

You can also use VMware Converter. It's free.

or still try this:

cmd

cd C:\Program Files\VMware\VMware Workstation

vmware-vdiskmanager.exe -r "C:\VM\myVM\beforeconversion.vmdk" -t 1 "C:\VM\myVM\afterconversion.vmdk"

0 Kudos
continuum
Immortal
Immortal

Why do you want to change the nominal size ?

If you convert to a split growing disk with vmware-vdiskmanager - there is no need to resize the vmdk.

Don't use Converter unless you are aware of the problems - in many scenarios it messes up drivers and may trigger a re-activation with MS

___________________________________

description of vmx-parameters:

VMware-liveCD:


________________________________________________
Do you need support with a VMFS recovery problem ? - send a message via skype "sanbarrow"
I do not support Workstation 16 at this time ...

0 Kudos
Peter_vm
Immortal
Immortal

Don't use Converter unless you are aware of the problems - in many scenarios it messes up drivers and may trigger a re-activation with MS

Many VM operations can trigger MS reactivation, that is a completely different topic.

I have never encountered "messed up drivers" with VMware Converted virtual systems, but I believe you that is possible.

0 Kudos
continuum
Immortal
Immortal

Just consider someone installed a XP following defaults - if he now converts the disk with vdiskmanager from preallocated to sparse - the guest doesn't even notice it.

If he resizes with Converter - the guest is messed up - as drivers are changed to SCSI which is not what the user wanted.

___________________________________

description of vmx-parameters:

VMware-liveCD:


________________________________________________
Do you need support with a VMFS recovery problem ? - send a message via skype "sanbarrow"
I do not support Workstation 16 at this time ...

0 Kudos
Peter_vm
Immortal
Immortal

You have probably a good point here.

I have never converted XP with IDE virtual disks, I always used LSILogic SCSI disks to start with.

0 Kudos
fgl
Enthusiast
Enthusiast

Thanks guys for your input. I was able to shrink and changed it from pre-allocated to expandable with the right combination of steps. In case you want to know how I did it.

Step 1. vmware-vdiskmanager -r old.vmdk -t 0 new.vmdk

Step 2. edit the vmx file to reflect the new.vmdk

Step 3. delete the old.vmdk disk and add the new.vmdk in the VM settings.

Step 4. shrink the VM via the vmtools.

It took about 3 hours in total.

0 Kudos