Increasing Disk Size on Existing VM Disk
When you’re using your Proxmox server you might run in the problem of not having enough HDD space defined for some of your VMs, using ZFS (pools) it’s really easy to fix this.
Since all my VM disks are simple files you can easily increase their size by running the following command:
qm resize <vmid> <disk> <size>
Let’s say you have a VM with a disk named vm-100-disk-0 and you wan to increase the disk size by 100GB, you just run
qm resize 100 vm-100-disk-0 +100G
Now you need to tell the VM to use the newly added space, first you need to check if the system sees the new space by running
dmesg | grep sda
Now we need the right partition to add the space to, run the following to check which partitions there are
fdisk -l /dev/sda | grep ^/dev
(Just make sure you’re grepping the right device, vda is also a possibility.)
Now run pared with the right device
parted /dev/sda
It will ask you to fix the unused space, enter F
for fix, then run
resizepart 3 100%
That’s it, no need to reboot!
You can find a more detailed description at the source: https://pve.proxmox.com/wiki/Resize_disks