Open andrei-toterman opened 6 months ago
Experienced this some while back. It's nice this is now reported.
If anyone needs to manually be able to expand that disk, this may help (my notes):
Troubleshoot - if you resize disk, but Ubuntu doesn’t see it that way.
$ sudo fdisk -l /dev/sda
Within Ubuntu, to see the disk image size
$ sudo parted -l
# On host: $ multipass restart {name}
Describe the bug Normally, when you increase the disk size of an instance (
mp set local.instance.disk=...
), the root partition gets resized by cloud-init to use the newly available space on the disk. But when the disk is already used at full capacity, increasing the disk size will not automatically increase the root partition size.To Reproduce
multipass exec instance -- dd if=/dev/zero of=big_file bs=1M count=10000 # or more if needed to fill the disk
multipass stop instance
multipass set local.instance.disk=20GB # or more than the current size
multipass exec instance lsblk
Expected behavior Have
/dev/sda1
expand to take up the available space in/dev/sda
.