Am 07.03.25 um 14:19 schrieb Fiona Ebner:
> Am 13.02.25 um 14:17 schrieb Dominik Csapak:
>> this now takes into account the 'not_allowed_nodes' hash we get from the
>> api call. With that, we can now limit the 'local_resources' check for
>> online vms only, as for offline guests, the 'unavailable-resources' hash
>> already includes mapped devices that don't exist on the target node.
>>
>> This now also includes unavailable storages on target nodes.
>>
>> Signed-off-by: Dominik Csapak <d.csa...@proxmox.com>
>> ---
>> changes in v6:
>> * added missing colon in log output
>>  PVE/API2/Nodes.pm | 14 +++++++++++++-
>>  1 file changed, 13 insertions(+), 1 deletion(-)
>>
>> diff --git a/PVE/API2/Nodes.pm b/PVE/API2/Nodes.pm
>> index 9cdf19db..f504e1b1 100644
>> --- a/PVE/API2/Nodes.pm
>> +++ b/PVE/API2/Nodes.pm
>> @@ -2331,11 +2331,23 @@ my $create_migrate_worker = sub {
>>          $invalidConditions .= join(', ', map { $_->{volid} } 
>> @{$preconditions->{local_disks}});
>>      }
>>  
>> -    if (@{$preconditions->{local_resources}}) {
>> +    if ($online && scalar($preconditions->{local_resources}->@*)) {
> 
> Hmm, what about non-usb/pci local devices that are not covered by the
> 'unavailable-resources' below? I.e. ivshmem/serial/parallel. You break
> the check for offline migration against those.

And actually also the not-mapped USB/PCI devices or?


_______________________________________________
pve-devel mailing list
pve-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel

Reply via email to