2014-09-06 Junichi Satoh <junichi@rworks.jp>
* lib/PandoraFMS/Core.pm: Fixed that unknown modules are never recovered when module data is received correctly in/after the race condition (module execution time exceeds its interval).
This commit is contained in:
parent
c7c1203a36
commit
8808685b8b
|
@ -1,3 +1,9 @@
|
||||||
|
2014-09-06 Junichi Satoh <junichi@rworks.jp>
|
||||||
|
|
||||||
|
* lib/PandoraFMS/Core.pm: Fixed that unknown modules are never
|
||||||
|
recovered when module data is received correctly in/after the
|
||||||
|
race condition (module execution time exceeds its interval).
|
||||||
|
|
||||||
2014-09-03 Ramon Novoa <rnovoa@artica.es>
|
2014-09-03 Ramon Novoa <rnovoa@artica.es>
|
||||||
|
|
||||||
* lib/PandoraFMS/Tools.pm: Added basic support to log to syslog.
|
* lib/PandoraFMS/Tools.pm: Added basic support to log to syslog.
|
||||||
|
|
|
@ -4223,7 +4223,7 @@ sub pandora_module_unknown ($$) {
|
||||||
|
|
||||||
# Set the module state to normal
|
# Set the module state to normal
|
||||||
logger ($pa_config, "Module " . $module->{'nombre'} . " is going to NORMAL", 10);
|
logger ($pa_config, "Module " . $module->{'nombre'} . " is going to NORMAL", 10);
|
||||||
db_do ($dbh, 'UPDATE tagente_estado SET last_known_status = estado, last_status = 0, estado = 0 WHERE id_agente_estado = ?', $module->{'id_agente_estado'});
|
db_do ($dbh, 'UPDATE tagente_estado SET last_status = 0, estado = 0 WHERE id_agente_estado = ?', $module->{'id_agente_estado'});
|
||||||
|
|
||||||
# Get agent information
|
# Get agent information
|
||||||
my $agent = get_db_single_row ($dbh, 'SELECT *
|
my $agent = get_db_single_row ($dbh, 'SELECT *
|
||||||
|
@ -4265,7 +4265,7 @@ sub pandora_module_unknown ($$) {
|
||||||
else {
|
else {
|
||||||
# Set the module state to unknown
|
# Set the module state to unknown
|
||||||
logger ($pa_config, "Module " . $module->{'nombre'} . " is going to UNKNOWN", 10);
|
logger ($pa_config, "Module " . $module->{'nombre'} . " is going to UNKNOWN", 10);
|
||||||
db_do ($dbh, 'UPDATE tagente_estado SET last_known_status = estado, last_status = 3, estado = 3 WHERE id_agente_estado = ?', $module->{'id_agente_estado'});
|
db_do ($dbh, 'UPDATE tagente_estado SET last_status = 3, estado = 3 WHERE id_agente_estado = ?', $module->{'id_agente_estado'});
|
||||||
|
|
||||||
# Get agent information
|
# Get agent information
|
||||||
my $agent = get_db_single_row ($dbh, 'SELECT * FROM tagente WHERE id_agente = ?', $module->{'id_agente'});
|
my $agent = get_db_single_row ($dbh, 'SELECT * FROM tagente WHERE id_agente = ?', $module->{'id_agente'});
|
||||||
|
|
Loading…
Reference in New Issue