kvm: Set RAW format to RBD DATADISK (#5801)

While deploying a VM with data disk on Ceph the volume format was in
QCOW2.

Fixes #5531
This commit is contained in:
slavkap 2022-01-08 05:24:21 +02:00 committed by GitHub
parent feb4343abe
commit 48006de3e3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1463,7 +1463,7 @@ public class KVMStorageProcessor implements StorageProcessor {
primaryPool = storagePoolMgr.getStoragePool(primaryStore.getPoolType(), primaryStore.getUuid());
disksize = volume.getSize();
PhysicalDiskFormat format;
if (volume.getFormat() == null) {
if (volume.getFormat() == null || StoragePoolType.RBD.equals(primaryStore.getPoolType())) {
format = primaryPool.getDefaultFormat();
} else {
format = PhysicalDiskFormat.valueOf(volume.getFormat().toString().toUpperCase());