Technical

Resize imported ( from esxi ) disks, possible ?

Resize imported ( from esxi ) disks, possible ?

Yes, it’s possible to resize disks imported from ESXi in Proxmox. The Proxmox side is easy — extend the virtual disk in the GUI or with qm resize. The part everyone forgets is growing the partition inside the guest OS. Do that and you’re done.

Close-up of an open vintage hard disk drive showing internal components and caution labels.

Extend the virtual disk in Proxmox

First, shut down the VM. Then either use the GUI (select the VM, go to Hardware, select the disk, click Resize disk) or run this on the Proxmox host:

qm resize 100 scsi0 +20G

That adds 20G to the disk. Replace 100 with your VM ID and scsi0 with the actual disk ID. If the disk was imported from ESXi, it might be on local-lvm or a directory storage — the command works the same.

Grow the partition in Linux

Start the VM and log in. Check the disk with lsblk. You should see the extra space as free space after the last partition. If the partition you want to grow is the last one, you can use growpart:

growpart /dev/sda 1

Then resize the filesystem:

resize2fs /dev/sda1

For XFS, use xfs_growfs / instead. If the partition isn’t the last one, you’ll need to move things around with gparted — that’s a whole other pain.

Close-up of a vintage Iomega Ditto internal tape drive with circuit board exposure.

Grow the partition in Windows

Open Disk Management (diskmgmt.msc). Right-click the partition and choose Extend Volume. If the option is greyed out, the unallocated space isn’t right after the partition. You can use diskpart from an admin command prompt:

diskpart
list disk
select disk 0
list partition
select partition 1
extend

That extends the partition into the unallocated space. No reboot needed.

What if the disk won’t resize?

If qm resize fails with an error about the disk format, check if the disk is qcow2 or raw. For qcow2, you can use qemu-img resize on the host:

qemu-img resize /var/lib/vz/images/100/vm-100-disk-0.qcow2 +20G

Then rescan the disk in the VM. This is rare, but it happens with imported disks that have weird formats.

If you’re dealing with other Proxmox storage quirks, check out Proxmox NFS Storage Status Unknown on Second Node: Fix It. And if your VM is acting up after resizing, Trouble with Node Crashing in Proxmox might help.

Leave a comment

Comments are reviewed before they appear. Your email is never published.