Fixes: 46d1225e ("drive device: fix regression with missing '/dev/disk/by-id' paths") Signed-off-by: Fiona Ebner <f.eb...@proxmox.com> --- src/PVE/QemuServer.pm | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/src/PVE/QemuServer.pm b/src/PVE/QemuServer.pm index 99d4da4f..78cfad62 100644 --- a/src/PVE/QemuServer.pm +++ b/src/PVE/QemuServer.pm @@ -1235,8 +1235,11 @@ sub print_drivedevice_full { } $device .= ",id=$drive_id"; - # for the switch to -blockdev, the SCSI device ID needs to be explicitly specified - if (min_version($machine_version, 10, 0)) { + # For the switch to -blockdev, the SCSI device ID needs to be explicitly specified. Note + # that only ide-cd and ide-hd have a 'device_id' option. + if ( + min_version($machine_version, 10, 0) && ($device_type eq 'cd' || $device_type eq 'hd') + ) { $device .= ",device_id=drive-${drive_id}"; } -- 2.47.2 _______________________________________________ pve-devel mailing list pve-devel@lists.proxmox.com https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel