Jump to content
We're Hiring! Full Stack Developer ×

Resize VM Image


rajsri

Recommended Posts

Hello,

I have a Windows 8.1 VM created in unRaid 6.1.3 with 200GB of disk size for the VM disk itself.

I ended up replacing my HDD cache pool with single SSD cache disk (I backed up the VM disk image and the XML before the replacement).

Now, how I can resize the disk size and re-import?

I created a new VM and then I used the following command to resize the old VM image:

sudo qemu-img resize vmdisk1.img 50G

and replaced the new VM image with the resized image (and the XML as well). The VM does not start.

 

Any documented method to resize/compact existing VM image file? Thanks!

 

Link to comment

Reducing a virtual disk image in size is tougher than increasing, but I believe it's possible.  Have you tried this guide:

 

http://nairobi-embedded.org/manipulating_disk_images_with_qemu-img.html#resizing-an-existing-disk-image-file

 

I believe I need to boot into the VM to run some of the commands, if so I cannot try this as my SSD is smaller than the VM image (I am not a Linux expert, sorry if my understanding is incorrect)

Link to comment

I believe I need to boot into the VM to run some of the commands, if so I cannot try this as my SSD is smaller than the VM image (I am not a Linux expert, sorry if my understanding is incorrect)

Temporarily copy the backed up full size image to an array drive and run the VM from there until you get it shrunk down to size.
Link to comment

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...