2008-01-08 Sancho Lerena <slerena@gmail.com>

* pandoradb_data.sql: Added keep_alive as module id 100 for the new keepalive
        management. Old way (from 1.2) is now deprecated and not used.

        * operation/agentes/estado_agente.php: Style changes, not code.

        * images/mod_keepalive.png: Added new icon for keepalive moduletype.

        * godmode/agentes/configurar_agente.php: Create an agent creates automatically 
        a keepalive module AND a tagente_estado record.



git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@688 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
slerena 2008-01-08 18:49:39 +00:00
parent bb4745b955
commit 6586e86d59
5 changed files with 22 additions and 4 deletions

View File

@ -1,3 +1,15 @@
2008-01-08 Sancho Lerena <slerena@gmail.com>
* pandoradb_data.sql: Added keep_alive as module id 100 for the new keepalive
management. Old way (from 1.2) is now deprecated and not used.
* operation/agentes/estado_agente.php: Style changes, not code.
* images/mod_keepalive.png: Added new icon for keepalive moduletype.
* godmode/agentes/configurar_agente.php: Create an agent creates automatically
a keepalive module AND a tagente_estado record.
2007-12-16 Sancho Lerena <slerena@gmail.com>
* pandoradb.sql: New field for tagente_modulo: disabled, to be

View File

@ -118,8 +118,14 @@ if (isset($_POST["create_agent"])) { // Create a new and shining agent
$agent_created_ok = 1;
$id_agente = mysql_insert_id();
// Create special MODULE agent_keepalive
$sql_insert ="INSERT INTO tagente_modulo (nombre, id_agente, id_tipo_modulo, descripcion) VALUES ('agent_keepalive', ".$id_agente.",-1,'Agent Keepalive monitor')";
$sql_insert ="INSERT INTO tagente_modulo (nombre, id_agente, id_tipo_modulo, descripcion) VALUES ('agent_keepalive', ".$id_agente.",100,'Agent Keepalive monitor')";
$result=mysql_query($sql_insert);
$id_agent_module = mysql_insert_id();
// And create MODULE agent_keepalive in tagente_estado table
$sql_insert2 ="INSERT INTO tagente_estado (id_agente_modulo, datos, timestamp, cambio, estado, id_agente, last_try, utimestamp, current_interval, running_by, last_execution_try) VALUES ($id_agent_module, 1, '', 0, 1, $id_agente, 0,0,0,0,0)";
$result = mysql_query ($sql_insert2);
// Create address for this agent in taddress
agent_add_address ($id_agente, $direccion_agente);
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 595 B

View File

@ -177,11 +177,11 @@ if (comprueba_login() == 0) {
$numero_monitor++;
$monitor_down++;
}
elseif ($est_modulo <> 100) { // estado=100 are data modules
elseif ($est_modulo != 100) { // estado=100 are data modules
$estado_general = $estado_general + $est_modulo;
$estado_cambio = $estado_cambio + $row_t["cambio"];
$numero_monitor ++;
if ($est_modulo <> 0)
if ($est_modulo != 0)
$monitor_bad++;
else
$monitor_ok++;

View File

@ -161,7 +161,7 @@ INSERT INTO `torigen` VALUES ('Operating System event'),('IDS events'),('Firewal
-- Dumping data for table `ttipo_modulo`
--
INSERT INTO `ttipo_modulo` VALUES (1,'generic_data',0,'Generic module to adquire numeric data','mod_data.png'),(2,'generic_proc',1,'Generic module to adquire boolean data','mod_proc.png'),(3,'generic_data_string',0,'Generic module to adquire alphanumeric data','mod_string.png'),(4,'generic_data_inc',0,'Generic module to adquire numeric incremental data','mod_data_inc.png'),(6,'remote_icmp_proc',3,'Remote ICMP network agent, boolean data','mod_icmp_proc.png'),(7,'remote_icmp',2,'Remote ICMP network agent (latency)','mod_icmp_data.png'),(8,'remote_tcp',2,'Remote TCP network agent, numeric data','mod_tcp_data.png'),(9,'remote_tcp_proc',3,'Remote TCP network agent, boolean data','mod_tcp_proc.png'),(10,'remote_tcp_string',2,'Remote TCP network agent, alphanumeric data','mod_tcp_string.png'),(11,'remote_tcp_inc',2,'Remote TCP network agent, incremental data','mod_tcp_inc.png'),(15,'remote_snmp',2,'Remote SNMP network agent, numeric data','mod_snmp_data.png'),(16,'remote_snmp_inc',2,'Remote SNMP network agent, incremental data','mod_snmp_inc.png'),(17,'remote_snmp_string',2,'Remote SNMP network agent, alphanumeric data','mod_snmp_string.png'),(18,'remote_snmp_proc',1,'Remote SNMP network agent, boolean data','mod_snmp_proc.png');
INSERT INTO `ttipo_modulo` VALUES (1,'generic_data',0,'Generic module to adquire numeric data','mod_data.png'),(2,'generic_proc',1,'Generic module to adquire boolean data','mod_proc.png'),(3,'generic_data_string',0,'Generic module to adquire alphanumeric data','mod_string.png'),(4,'generic_data_inc',0,'Generic module to adquire numeric incremental data','mod_data_inc.png'),(6,'remote_icmp_proc',3,'Remote ICMP network agent, boolean data','mod_icmp_proc.png'),(7,'remote_icmp',2,'Remote ICMP network agent (latency)','mod_icmp_data.png'),(8,'remote_tcp',2,'Remote TCP network agent, numeric data','mod_tcp_data.png'),(9,'remote_tcp_proc',3,'Remote TCP network agent, boolean data','mod_tcp_proc.png'),(10,'remote_tcp_string',2,'Remote TCP network agent, alphanumeric data','mod_tcp_string.png'),(11,'remote_tcp_inc',2,'Remote TCP network agent, incremental data','mod_tcp_inc.png'),(15,'remote_snmp',2,'Remote SNMP network agent, numeric data','mod_snmp_data.png'),(16,'remote_snmp_inc',2,'Remote SNMP network agent, incremental data','mod_snmp_inc.png'),(17,'remote_snmp_string',2,'Remote SNMP network agent, alphanumeric data','mod_snmp_string.png'),(18,'remote_snmp_proc',1,'Remote SNMP network agent, boolean data','mod_snmp_proc.png'), (100,'keep_alive',-1,'KeepAlive','mod_keepalive.png');
--
-- Dumping data for table `tusuario`