mirror of
https://git.proxmox.com/git/qemu-server
synced 2025-08-06 00:00:47 +00:00
create_efidisk: poll the real size after volume creation
some storage backends have bigger granularity than the default 128k size from the EFIVARS template file, so we actually need to poll the real created disk size, as it will be used to create the target volume for local storage migration on running VMs, if it's to small the target will be to small and migration will fail. Just a fix for newly created EFIDISKS, for others we need to rescan the size after we've got the migrate lock and write the updated info out, so that the target node has the correct one (protected from migrate lock). Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
This commit is contained in:
parent
dad06e2068
commit
340dbcf730
@ -7078,8 +7078,9 @@ sub create_efidisk($$$$$) {
|
||||
PVE::Storage::activate_volumes($storecfg, [$volid]);
|
||||
|
||||
qemu_img_convert($ovmf_vars, $volid, $vars_size_b, undef, 0);
|
||||
my ($size) = PVE::Storage::volume_size_info($storecfg, $volid, 3);
|
||||
|
||||
return ($volid, $vars_size);
|
||||
return ($volid, $size/1024);
|
||||
}
|
||||
|
||||
sub vm_iothreads_list {
|
||||
|
Loading…
Reference in New Issue
Block a user