mirror of
https://git.proxmox.com/git/qemu-server
synced 2025-08-05 20:36:20 +00:00
fix #1697: only check machine type for pxe
it is not necessary to check the romfile of the running vm for .pxe machine types, since the machine type itself is not hot-pluggable Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
This commit is contained in:
parent
fd950b2385
commit
3807f3e4ee
@ -6464,13 +6464,8 @@ sub qemu_machine_pxe {
|
||||
|
||||
$machine = PVE::QemuServer::get_current_qemu_machine($vmid) if !$machine;
|
||||
|
||||
foreach my $opt (keys %$conf) {
|
||||
next if $opt !~ m/^net(\d+)$/;
|
||||
my $net = PVE::QemuServer::parse_net($conf->{$opt});
|
||||
next if !$net;
|
||||
my $romfile = PVE::QemuServer::vm_mon_cmd_nocheck($vmid, 'qom-get', path => $opt, property => 'romfile');
|
||||
return $machine.".pxe" if $romfile =~ m/pxe/;
|
||||
last;
|
||||
if ($conf->{machine} && $conf->{machine} =~ m/\.pxe$/) {
|
||||
$machine .= '.pxe';
|
||||
}
|
||||
|
||||
return $machine;
|
||||
|
Loading…
Reference in New Issue
Block a user