2011-11-15 Sergio Martin <sergio.martin@artica.es>
* util/pandora_manage.pl: Changed cli function to pandora function to reuse it in future git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@5137 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
af6a48581a
commit
97b59fcdd5
|
@ -1,3 +1,8 @@
|
||||||
|
2011-11-15 Sergio Martin <sergio.martin@artica.es>
|
||||||
|
|
||||||
|
* util/pandora_manage.pl: Changed cli function to pandora function
|
||||||
|
to reuse it in future
|
||||||
|
|
||||||
2011-11-15 Sancho Lerena <slerena@artica.es>
|
2011-11-15 Sancho Lerena <slerena@artica.es>
|
||||||
|
|
||||||
* util/pandora_db.pl: Small optimization in module deletion. Instead
|
* util/pandora_db.pl: Small optimization in module deletion. Instead
|
||||||
|
|
|
@ -303,6 +303,17 @@ sub pandora_validate_event_filter ($$$$$$$$$) {
|
||||||
db_do ($dbh, "UPDATE tevento SET estado = 1 WHERE estado = 0".$filter);
|
db_do ($dbh, "UPDATE tevento SET estado = 1 WHERE estado = 0".$filter);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
###############################################################################
|
||||||
|
# Get list of all downed agents
|
||||||
|
###############################################################################
|
||||||
|
sub pandora_get_downed_agents () {
|
||||||
|
my @downed_agents = get_db_rows ($dbh, "SELECT tagente.nombre, truncate((NOW() - tagente.ultimo_contacto/60),0) as downed_time, tagente.server_name from tagente
|
||||||
|
where UNIX_TIMESTAMP(NOW()) - UNIX_TIMESTAMP(tagente.ultimo_contacto)>(tagente.intervalo*2)
|
||||||
|
OR tagente.ultimo_contacto=0");
|
||||||
|
|
||||||
|
return \@downed_agents;
|
||||||
|
}
|
||||||
|
|
||||||
###############################################################################
|
###############################################################################
|
||||||
###############################################################################
|
###############################################################################
|
||||||
# PRINT HELP AND CHECK ERRORS FUNCTIONS
|
# PRINT HELP AND CHECK ERRORS FUNCTIONS
|
||||||
|
|
Loading…
Reference in New Issue