Converting from thin provisioning to thick provisioning

Last Updated : Dec 13, 2024 |

About this task

The WebLM-<version number>-KVM-4E-disk1.qcow2 images are in thin provision format. You must convert the qcow2 images to thick provision. When running the commands to convert to thick provision, add a unique identifier to the new qcow2 image, such as WebLM-<version number>-KVM-4E-THICKdisk1.qcow2.

Procedure

  1. Go to the /var/lib/libvirt/staging folder, and run the following command to convert the thin qcow image to a thick qcow image:

    sudo qemu-img convert -O qcow2 -o preallocation=full WebLM-<version number>-KVM-4E-disk1.qcow2 WebLM-<version number>-KVM-4E-THICKdisk1.qcow2

  2. Run the following command to verify the disk size and that the conversion is successful:

    sudo qemu-img info WebLM-<version number>-KVM-4E-THICKdisk1.qcow2

    The disk size must display as 40 GB.