Allow formatting a partition inside qcow2 image
|Category:||Drivers - Storage|
When creating a datablock, it would be very useful if it was possible to format a partition with e.g. ext3 inside a qcow2 file.
I am not sure how it could be implemented. The sunstone interface has a
DRIVER field, for which the help reads “KVM: raw, qcow2”, so I figured that using
ext3 as filesystem type and
driver should make a qcow2 file with an ext3 partition inside.
The attached patch adds this feature, but I'm not sure it's the way to go. Note that the ext3 partition is created on a raw file, which is then converted to qcow2. Creating a qcow2 file before formatting to ext3 is tricky because it would mean using qemu-nbd which requires an available nbd file, and root privileges.
#4 Updated by Ruben S. Montero about 6 years ago
- Status changed from Pending to Closed
This would also be tricky for other hypervisors like VMware. In that case we also create an unformatted disk, that is then formatted by the guest. This is the standard approach.
This way we think that is more consistent to keep qcow2 and vmfs as unformatted.
THANKS for your contribution!!!!!