1
0
mirror of https://github.com/OpenNebula/one.git synced 2025-03-16 22:50:10 +03:00

M #-: Refresh counter when host is on error

This commit is contained in:
Ruben S. Montero 2020-05-25 20:07:35 +02:00
parent 73c0a96747
commit 707f48980c
No known key found for this signature in database
GPG Key ID: A0CEA6FA880A1D87

View File

@ -551,14 +551,16 @@ void HostMonitorManager::error_monitor(int oid, const string& msg)
return;
}
host->monitor_in_progress(false);
if (host->state() == Host::OFFLINE)
{
// Host is offline, we shouldn't receive monitoring
return;
}
host->monitor_in_progress(false);
host->last_monitored(time(nullptr));
ostringstream oss;
oss << Host::state_to_str(Host::ERROR) << " " << msg;