Resize KVM (qemu) disk

 

On host machine:

To expand the size of the image, we would run the following command:

$ qemu-img resize disk1.qcow2 30G

As an alternative, instead of the absolute size, we could specify the size increment:

$ qemu-img resize disk1.qcow2 +10G
 
On guest linux operating system:
Using gparted extend the partition with the additional space.
Or
growpart /dev/xvda 1  # Grows the partition size
resize2fs /dev/xvda1  # Grows the filesystem 

(growpart is part of cloud-util)
 

 

Comentarii

Postări populare de pe acest blog

Process Command Line Arguments in Python

SQL injection with UNION

Docker compose DNS resolution