]> git.proxmox.com Git - pve-ha-manager.git/commitdiff
manager: service start: make EWRONG_NODE a non-fatal error
authorThomas Lamprecht <t.lamprecht@proxmox.com>
Mon, 20 Mar 2023 08:49:10 +0000 (09:49 +0100)
committerThomas Lamprecht <t.lamprecht@proxmox.com>
Mon, 20 Mar 2023 10:09:01 +0000 (11:09 +0100)
traverse the usual error counting mechanisms, as then the
select_service_node helper either picks up the right node and it
starts there or it can trigger fencing of that.

Note, in practice this normally can only happen if the admin
butchered around in the node cluster state, but as we only select the
safe nodes from the configured groups, we should be safe in any case.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
src/PVE/HA/Manager.pm

index 5fcabffe76bcb5f269292dc18b1ff9f5a9996fc6..70c66ffff6aab62a311d9a5f83806351efcd5b2e 100644 (file)
@@ -773,7 +773,7 @@ sub next_state_started {
                    # store flag to indicate successful start - only valid while state == 'started'
                    $sd->{running} = 1;
 
-               } elsif ($ec == ERROR) {
+               } elsif ($ec == ERROR || $ec == EWRONG_NODE) {
 
                    delete $sd->{running};