Charles, you didn't say if the image is the boot image or an external device that's mounted by the VM. If it's the boot image
I am almost sure you have to reboot when you extend the qcow2--actually whenever I've done it I've actually shut down before
even growing the qcow2 image and resizing the file system. Note I haven't been running Xen for quite some time and there might be new features now of which I am unaware, but as far as I know it doesn't depend on the hypervisor you are using, KVM has same issue.
Steve Timm.
From: Xen-users <xen-users-bounces@xxxxxxxxxxxxxxxxxxxx> on behalf of Charles Koprowski <charles@xxxxxxxxxx>
Sent: Thursday, December 23, 2021 5:45 AM
To: xen-users@xxxxxxxxxxxxx <xen-users@xxxxxxxxxxxxx>
Subject: Re: RAW / Qcow disk image online resizing
First detect the correct loop device with the command:
losetup -j /path/to/disk.img
Then resize the loop device, for example /dev/loop0, with the following command:
losetup -c /dev/loop0
But I have not yet found an equivalent for Qcow.
Regards,
Le mar. 21 déc. 2021 à 13:34, Charles Koprowski <charles@xxxxxxxxxx> a écrit :
Hello,
Is it possible to expand the disk capacity of a domU that uses a RAW or Qcow disk image?
I usually do this with domUs whose disks are LVM volumes using lvextend from the dom0 and then resize2fs from the domU.
But when I extend a RAW or Qcow image with qemu-img extend, the new disk size is not propagated to the domU until the next reboot.
Thank you
--
|