Increase the disksize of a VM (on Unraid)
··117 words·1 min
Following these steps should suffice.
First of all, shutdown the VM
Get some info about the image (I use a raw disk usually)
$ qemu-img info -f raw vdisk1.img
Resize the image (add 40 gigabytes)
$ qemu-img resize -f raw vdisk1.img +40G
Start the VM and log into a terminal on the VM
Resize the filesystems partition up to 100%
$ sudo parted /dev/vda resizepart 2 100%
Extend the filesystem on the resized partition (I use btrfs here)
$ sudo btrfs filesystem resize max /
Additional information for other filesystems
For the classic ext4 filesystem it should be (not tested yet):$ sudo resize2fs /dev/vda2
Reboot the VM
That’s it. Following a few sources: