]> git.proxmox.com Git - pve-ha-manager.git/blobdiff - src/PVE/HA/Sim/RTHardware.pm
correctly reset node status on power on/off
[pve-ha-manager.git] / src / PVE / HA / Sim / RTHardware.pm
index 54f6fbaace25d2ecab4834acbfc201a919a41fcd..2148e20ad4bc669123a60f49e794ccb999d170ff 100644 (file)
@@ -207,7 +207,7 @@ sub sim_hardware_cmd {
        
        if ($cmd eq 'power') {
            if ($cstatus->{$node}->{power} ne $action) {
-               if ($action eq 'on') {        
+               if ($action eq 'on') {
                    $d->{crm} = $self->fork_daemon($lockfh, 'crm', $node) if !$d->{crm};
                    $d->{lrm} = $self->fork_daemon($lockfh, 'lrm', $node) if !$d->{lrm};
                } else {
@@ -222,6 +222,7 @@ sub sim_hardware_cmd {
                        $d->{lrm} = undef;
                    }
                    $self->watchdog_reset_nolock($node);
+                   $self->write_service_status($node, {});
                }
            }