2007-03-12 18:58:52 +01:00
|
|
|
|
2007-05-20 19:12:31 +02:00
|
|
|
-- Pandora FMS official tables for 1.3 version
|
2007-03-12 18:58:52 +01:00
|
|
|
|
|
|
|
CREATE TABLE `taddress` (
|
|
|
|
`id_a` bigint(20) unsigned NOT NULL auto_increment,
|
|
|
|
`ip` varchar(15) NOT NULL default '',
|
|
|
|
`ip_pack` int(10) unsigned NOT NULL default '0',
|
|
|
|
PRIMARY KEY (`id_a`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2007-03-12 18:58:52 +01:00
|
|
|
|
|
|
|
|
|
|
|
CREATE TABLE `taddress_agent` (
|
|
|
|
`id_ag` bigint(20) unsigned NOT NULL auto_increment,
|
|
|
|
`id_a` bigint(20) unsigned NOT NULL default '0',
|
|
|
|
`id_agent` mediumint(8) unsigned NOT NULL default '0',
|
|
|
|
PRIMARY KEY (`id_ag`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2007-03-12 18:58:52 +01:00
|
|
|
|
|
|
|
|
2006-03-27 05:37:27 +02:00
|
|
|
CREATE TABLE `tagent_access` (
|
|
|
|
`id_ac` bigint(20) unsigned NOT NULL auto_increment,
|
2007-03-12 18:58:52 +01:00
|
|
|
`id_agent` int(11) NOT NULL default '0',
|
2006-03-27 05:37:27 +02:00
|
|
|
`timestamp` datetime NOT NULL default '0000-00-00 00:00:00',
|
2007-03-12 18:58:52 +01:00
|
|
|
`utimestamp` bigint(20) NOT NULL default '0',
|
2006-03-27 05:37:27 +02:00
|
|
|
PRIMARY KEY (`id_ac`),
|
2007-04-18 11:58:26 +02:00
|
|
|
KEY `agent_index` (`id_agent`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2006-03-27 05:37:27 +02:00
|
|
|
|
2007-03-12 18:58:52 +01:00
|
|
|
|
2006-03-27 05:37:27 +02:00
|
|
|
CREATE TABLE `tagente` (
|
2007-03-12 18:58:52 +01:00
|
|
|
`id_agente` mediumint(8) unsigned NOT NULL auto_increment,
|
2006-03-27 05:37:27 +02:00
|
|
|
`nombre` varchar(100) NOT NULL default '',
|
|
|
|
`direccion` varchar(100) default '',
|
|
|
|
`comentarios` varchar(255) default '',
|
2007-03-12 18:58:52 +01:00
|
|
|
`id_grupo` int(10) unsigned NOT NULL default '0',
|
2007-04-18 19:17:06 +02:00
|
|
|
`ultimo_contacto` datetime NOT NULL default '0000-00-00 00:00:00',
|
2007-03-12 18:58:52 +01:00
|
|
|
`modo` tinyint(1) NOT NULL default '0',
|
2007-03-28 16:51:39 +02:00
|
|
|
`intervalo` int(11) NOT NULL default '300',
|
|
|
|
`id_os` int(10) unsigned default '0',
|
2006-03-27 05:37:27 +02:00
|
|
|
`os_version` varchar(100) default '',
|
|
|
|
`agent_version` varchar(100) default '',
|
|
|
|
`ultimo_contacto_remoto` datetime default '0000-00-00 00:00:00',
|
2007-03-12 18:58:52 +01:00
|
|
|
`disabled` tinyint(2) NOT NULL default '0',
|
|
|
|
`agent_type` int(2) unsigned NOT NULL default '0',
|
|
|
|
`id_server` int(10) unsigned default '0',
|
2006-03-27 05:37:27 +02:00
|
|
|
PRIMARY KEY (`id_agente`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2007-03-12 18:58:52 +01:00
|
|
|
|
2006-03-27 05:37:27 +02:00
|
|
|
|
|
|
|
CREATE TABLE `tagente_datos` (
|
2007-03-12 18:58:52 +01:00
|
|
|
`id_agente_datos` bigint(10) unsigned NOT NULL auto_increment,
|
|
|
|
`id_agente_modulo` mediumint(8) unsigned NOT NULL default '0',
|
2006-09-21 18:30:34 +02:00
|
|
|
`datos` double(18,2) default NULL,
|
2006-03-27 05:37:27 +02:00
|
|
|
`timestamp` datetime NOT NULL default '0000-00-00 00:00:00',
|
2007-02-22 16:47:58 +01:00
|
|
|
`id_agente` mediumint(8) unsigned NOT NULL default '0',
|
2007-03-12 18:58:52 +01:00
|
|
|
`utimestamp` int(10) unsigned default '0',
|
2006-03-27 05:37:27 +02:00
|
|
|
PRIMARY KEY (`id_agente_datos`),
|
2007-03-12 18:58:52 +01:00
|
|
|
KEY `data_index2` (`id_agente`,`id_agente_modulo`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2007-03-12 18:58:52 +01:00
|
|
|
|
2006-03-27 05:37:27 +02:00
|
|
|
|
|
|
|
CREATE TABLE `tagente_datos_inc` (
|
|
|
|
`id_adi` bigint(20) unsigned NOT NULL auto_increment,
|
2007-03-12 18:58:52 +01:00
|
|
|
`id_agente_modulo` bigint(20) NOT NULL default '0',
|
|
|
|
`datos` bigint(12) default NULL,
|
2006-03-27 05:37:27 +02:00
|
|
|
`timestamp` datetime NOT NULL default '0000-00-00 00:00:00',
|
2007-05-20 19:12:31 +02:00
|
|
|
`utimestamp` int(10) unsigned default '0',
|
2006-03-27 05:37:27 +02:00
|
|
|
PRIMARY KEY (`id_adi`),
|
|
|
|
KEY `data_inc_index_1` (`id_agente_modulo`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2007-03-12 18:58:52 +01:00
|
|
|
|
2006-03-27 05:37:27 +02:00
|
|
|
|
|
|
|
CREATE TABLE `tagente_datos_string` (
|
|
|
|
`id_tagente_datos_string` bigint(20) unsigned NOT NULL auto_increment,
|
2007-03-12 18:58:52 +01:00
|
|
|
`id_agente_modulo` int(11) NOT NULL default '0',
|
2007-04-18 19:17:06 +02:00
|
|
|
`datos` tinytext NOT NULL,
|
2006-03-27 05:37:27 +02:00
|
|
|
`timestamp` datetime NOT NULL default '0000-00-00 00:00:00',
|
2007-03-12 18:58:52 +01:00
|
|
|
`id_agente` bigint(4) unsigned NOT NULL default '0',
|
2007-03-28 16:51:39 +02:00
|
|
|
`utimestamp` int(10) unsigned NOT NULL default 0,
|
2006-03-27 05:37:27 +02:00
|
|
|
PRIMARY KEY (`id_tagente_datos_string`),
|
2007-03-12 18:58:52 +01:00
|
|
|
KEY `data_string_index_1` (`id_agente_modulo`),
|
2007-03-28 16:51:39 +02:00
|
|
|
KEY `data_string_index_2` (`id_agente`)
|
|
|
|
) ENGINE=InnoDB;
|
2006-03-27 05:37:27 +02:00
|
|
|
|
2007-03-12 18:58:52 +01:00
|
|
|
|
2006-03-27 05:37:27 +02:00
|
|
|
CREATE TABLE `tagente_estado` (
|
|
|
|
`id_agente_estado` int(10) unsigned NOT NULL auto_increment,
|
2007-03-12 18:58:52 +01:00
|
|
|
`id_agente_modulo` int(20) NOT NULL default '0',
|
2006-03-27 05:37:27 +02:00
|
|
|
`datos` varchar(255) NOT NULL default '',
|
|
|
|
`timestamp` datetime NOT NULL default '0000-00-00 00:00:00',
|
2007-03-12 18:58:52 +01:00
|
|
|
`cambio` int(11) NOT NULL default '0',
|
|
|
|
`estado` int(11) NOT NULL default '0',
|
|
|
|
`id_agente` int(11) NOT NULL default '0',
|
2006-03-27 05:37:27 +02:00
|
|
|
`last_try` datetime default NULL,
|
2007-03-12 18:58:52 +01:00
|
|
|
`utimestamp` bigint(20) NOT NULL default '0',
|
|
|
|
`current_interval` int(10) unsigned NOT NULL default '0',
|
2007-03-28 16:51:39 +02:00
|
|
|
`running_by` int(10) unsigned NULL default 0,
|
2007-07-18 20:01:06 +02:00
|
|
|
`last_execution_try` bigint(20) NOT NULL default '0',
|
2006-03-27 05:37:27 +02:00
|
|
|
PRIMARY KEY (`id_agente_estado`),
|
2007-03-12 18:58:52 +01:00
|
|
|
KEY `status_index_1` (`id_agente_modulo`),
|
2006-03-27 05:37:27 +02:00
|
|
|
KEY `status_index_2` (`id_agente_modulo`,`estado`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
|
|
|
|
2007-04-18 11:58:26 +02:00
|
|
|
|
2007-03-28 16:51:39 +02:00
|
|
|
CREATE TABLE `tmodule` (
|
|
|
|
`id_module` int(11) unsigned NOT NULL auto_increment,
|
|
|
|
`name` varchar(100) NOT NULL default '',
|
2007-04-18 19:17:06 +02:00
|
|
|
PRIMARY KEY (`id_module`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
|
|
|
|
2007-03-12 18:58:52 +01:00
|
|
|
|
2006-03-27 05:37:27 +02:00
|
|
|
CREATE TABLE `tagente_modulo` (
|
2007-03-12 18:58:52 +01:00
|
|
|
`id_agente_modulo` bigint(100) unsigned NOT NULL auto_increment,
|
|
|
|
`id_agente` int(11) NOT NULL default '0',
|
|
|
|
`id_tipo_modulo` int(11) NOT NULL default '0',
|
2006-03-27 05:37:27 +02:00
|
|
|
`descripcion` varchar(100) NOT NULL default '',
|
|
|
|
`nombre` varchar(100) NOT NULL default '',
|
2007-03-12 18:58:52 +01:00
|
|
|
`max` bigint(20) default '0',
|
|
|
|
`min` bigint(20) default '0',
|
|
|
|
`module_interval` int(4) unsigned default '0',
|
|
|
|
`tcp_port` int(4) unsigned default '0',
|
2006-03-27 05:37:27 +02:00
|
|
|
`tcp_send` varchar(150) default '',
|
|
|
|
`tcp_rcv` varchar(100) default '',
|
|
|
|
`snmp_community` varchar(100) default '',
|
|
|
|
`snmp_oid` varchar(255) default '0',
|
|
|
|
`ip_target` varchar(100) default '',
|
|
|
|
`id_module_group` int(4) unsigned default '0',
|
2007-03-23 13:35:50 +01:00
|
|
|
`flag` tinyint(3) unsigned default '1',
|
2007-03-28 16:51:39 +02:00
|
|
|
`id_modulo` int(11) unsigned NULL default 0,
|
|
|
|
PRIMARY KEY (`id_agente_modulo`, `id_agente`),
|
2007-04-11 05:12:48 +02:00
|
|
|
KEY `tam_agente` (`id_agente`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2007-03-12 18:58:52 +01:00
|
|
|
|
2006-03-27 05:37:27 +02:00
|
|
|
|
|
|
|
CREATE TABLE `talert_snmp` (
|
|
|
|
`id_as` int(10) unsigned NOT NULL auto_increment,
|
|
|
|
`id_alert` int(10) unsigned NOT NULL default '0',
|
|
|
|
`al_field1` varchar(100) NOT NULL default '',
|
|
|
|
`al_field2` varchar(255) NOT NULL default '',
|
|
|
|
`al_field3` varchar(255) NOT NULL default '',
|
|
|
|
`description` varchar(255) default '',
|
|
|
|
`alert_type` int(2) unsigned NOT NULL default '0',
|
|
|
|
`agent` varchar(100) default '',
|
|
|
|
`custom_oid` varchar(200) default '',
|
|
|
|
`oid` varchar(255) NOT NULL default '',
|
2007-03-12 18:58:52 +01:00
|
|
|
`time_threshold` int(11) NOT NULL default '0',
|
2006-03-27 05:37:27 +02:00
|
|
|
`times_fired` int(2) unsigned NOT NULL default '0',
|
2007-04-18 19:17:06 +02:00
|
|
|
`last_fired` datetime NOT NULL default '0000-00-00 00:00:00',
|
2007-03-12 18:58:52 +01:00
|
|
|
`max_alerts` int(11) NOT NULL default '1',
|
|
|
|
`min_alerts` int(11) NOT NULL default '1',
|
2006-03-27 05:37:27 +02:00
|
|
|
`internal_counter` int(2) unsigned NOT NULL default '0',
|
|
|
|
PRIMARY KEY (`id_as`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2006-03-27 05:37:27 +02:00
|
|
|
|
2007-03-12 18:58:52 +01:00
|
|
|
|
2006-03-27 05:37:27 +02:00
|
|
|
CREATE TABLE `talerta` (
|
|
|
|
`id_alerta` int(10) unsigned NOT NULL auto_increment,
|
|
|
|
`nombre` varchar(100) NOT NULL default '',
|
|
|
|
`comando` varchar(100) default '',
|
|
|
|
`descripcion` varchar(255) default '',
|
|
|
|
PRIMARY KEY (`id_alerta`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2006-03-27 05:37:27 +02:00
|
|
|
|
|
|
|
|
|
|
|
CREATE TABLE `talerta_agente_modulo` (
|
2007-03-12 18:58:52 +01:00
|
|
|
`id_aam` int(11) unsigned NOT NULL auto_increment,
|
|
|
|
`id_agente_modulo` int(11) NOT NULL default '0',
|
|
|
|
`id_alerta` int(11) NOT NULL default '0',
|
2006-03-27 05:37:27 +02:00
|
|
|
`al_campo1` varchar(255) default '',
|
|
|
|
`al_campo2` varchar(255) default '',
|
2007-04-18 19:17:06 +02:00
|
|
|
`al_campo3` mediumtext NOT NULL,
|
2006-03-27 05:37:27 +02:00
|
|
|
`descripcion` varchar(255) default '',
|
2007-04-18 11:58:26 +02:00
|
|
|
`dis_max` double(18,2) default NULL,
|
|
|
|
`dis_min` double(18,2) default NULL,
|
2007-03-12 18:58:52 +01:00
|
|
|
`time_threshold` int(11) NOT NULL default '0',
|
2007-04-18 19:17:06 +02:00
|
|
|
`last_fired` datetime NOT NULL default '0000-00-00 00:00:00',
|
2007-03-12 18:58:52 +01:00
|
|
|
`max_alerts` int(4) NOT NULL default '1',
|
|
|
|
`times_fired` int(11) NOT NULL default '0',
|
|
|
|
`module_type` int(11) NOT NULL default '0',
|
|
|
|
`min_alerts` int(4) NOT NULL default '0',
|
|
|
|
`internal_counter` int(4) default '0',
|
2007-04-19 20:50:07 +02:00
|
|
|
`alert_text` varchar(255) default '',
|
2007-06-17 12:34:39 +02:00
|
|
|
`disable` int(4) default '0',
|
2007-06-21 17:48:47 +02:00
|
|
|
`time_from` int(8) default '0',
|
|
|
|
`time_to` int(8) default '0',
|
2006-03-27 05:37:27 +02:00
|
|
|
PRIMARY KEY (`id_aam`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2007-03-12 18:58:52 +01:00
|
|
|
|
2006-03-27 05:37:27 +02:00
|
|
|
|
|
|
|
CREATE TABLE `tattachment` (
|
2007-03-12 18:58:52 +01:00
|
|
|
`id_attachment` bigint(20) unsigned NOT NULL auto_increment,
|
|
|
|
`id_incidencia` bigint(20) NOT NULL default '0',
|
2006-03-27 05:37:27 +02:00
|
|
|
`id_usuario` varchar(60) NOT NULL default '',
|
|
|
|
`filename` varchar(255) NOT NULL default '',
|
|
|
|
`description` varchar(150) default '',
|
2007-03-12 18:58:52 +01:00
|
|
|
`size` bigint(20) NOT NULL default '0',
|
2006-03-27 05:37:27 +02:00
|
|
|
PRIMARY KEY (`id_attachment`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2007-03-12 18:58:52 +01:00
|
|
|
|
2006-03-27 05:37:27 +02:00
|
|
|
|
|
|
|
CREATE TABLE `tconfig` (
|
|
|
|
`id_config` int(10) unsigned NOT NULL auto_increment,
|
|
|
|
`token` varchar(100) NOT NULL default '',
|
|
|
|
`value` varchar(100) NOT NULL default '',
|
|
|
|
PRIMARY KEY (`id_config`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2006-03-27 05:37:27 +02:00
|
|
|
|
2007-03-12 18:58:52 +01:00
|
|
|
|
2006-03-27 05:37:27 +02:00
|
|
|
CREATE TABLE `tconfig_os` (
|
|
|
|
`id_os` int(10) unsigned NOT NULL auto_increment,
|
|
|
|
`name` varchar(100) NOT NULL default '',
|
|
|
|
`description` varchar(250) default '',
|
|
|
|
`icon_name` varchar(100) default '',
|
|
|
|
PRIMARY KEY (`id_os`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2007-03-12 18:58:52 +01:00
|
|
|
|
2006-03-27 05:37:27 +02:00
|
|
|
|
|
|
|
CREATE TABLE `tevento` (
|
|
|
|
`id_evento` bigint(20) unsigned NOT NULL auto_increment,
|
2007-03-12 18:58:52 +01:00
|
|
|
`id_agente` bigint(20) NOT NULL default '0',
|
2006-03-27 05:37:27 +02:00
|
|
|
`id_usuario` varchar(60) NOT NULL default '0',
|
2007-03-12 18:58:52 +01:00
|
|
|
`id_grupo` bigint(20) NOT NULL default '0',
|
|
|
|
`estado` int(10) unsigned NOT NULL default '0',
|
2006-03-27 05:37:27 +02:00
|
|
|
`timestamp` datetime NOT NULL default '0000-00-00 00:00:00',
|
|
|
|
`evento` varchar(255) NOT NULL default '',
|
2007-03-28 15:08:10 +02:00
|
|
|
`utimestamp` bigint(20) unsigned NOT NULL default '0',
|
2006-03-27 05:37:27 +02:00
|
|
|
PRIMARY KEY (`id_evento`),
|
2007-03-12 18:58:52 +01:00
|
|
|
KEY `indice_1` (`id_agente`,`id_evento`),
|
|
|
|
KEY `indice_2` (`timestamp`,`id_evento`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2007-03-12 18:58:52 +01:00
|
|
|
|
|
|
|
|
2006-03-27 05:37:27 +02:00
|
|
|
CREATE TABLE `tgrupo` (
|
|
|
|
`id_grupo` mediumint(8) unsigned NOT NULL auto_increment,
|
|
|
|
`nombre` varchar(100) NOT NULL default '',
|
|
|
|
`icon` varchar(50) default NULL,
|
2007-03-12 18:58:52 +01:00
|
|
|
`parent` tinyint(4) NOT NULL default '-1',
|
2007-05-01 15:34:03 +02:00
|
|
|
`disabled` tinyint(4) NOT NULL default '0',
|
2006-03-27 05:37:27 +02:00
|
|
|
PRIMARY KEY (`id_grupo`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2007-03-12 18:58:52 +01:00
|
|
|
|
2006-03-27 05:37:27 +02:00
|
|
|
|
|
|
|
CREATE TABLE `tincidencia` (
|
2007-03-12 18:58:52 +01:00
|
|
|
`id_incidencia` bigint(20) unsigned NOT NULL auto_increment,
|
2006-03-27 05:37:27 +02:00
|
|
|
`inicio` datetime NOT NULL default '0000-00-00 00:00:00',
|
|
|
|
`cierre` datetime NOT NULL default '0000-00-00 00:00:00',
|
|
|
|
`titulo` varchar(100) NOT NULL default '',
|
|
|
|
`descripcion` mediumtext NOT NULL,
|
|
|
|
`id_usuario` varchar(100) NOT NULL default '',
|
|
|
|
`origen` varchar(100) NOT NULL default '',
|
2007-03-12 18:58:52 +01:00
|
|
|
`estado` int(11) NOT NULL default '0',
|
|
|
|
`prioridad` int(11) NOT NULL default '0',
|
|
|
|
`id_grupo` mediumint(9) NOT NULL default '0',
|
2006-03-27 05:37:27 +02:00
|
|
|
`actualizacion` datetime NOT NULL default '0000-00-00 00:00:00',
|
|
|
|
`id_creator` varchar(60) default NULL,
|
2007-04-13 20:47:58 +02:00
|
|
|
`notify_email` TINYINT UNSIGNED NOT NULL DEFAULT 0,
|
2006-03-27 05:37:27 +02:00
|
|
|
PRIMARY KEY (`id_incidencia`),
|
|
|
|
KEY `incident_index_1` (`id_usuario`,`id_incidencia`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2006-03-27 05:37:27 +02:00
|
|
|
|
2007-03-12 18:58:52 +01:00
|
|
|
|
2006-03-27 05:37:27 +02:00
|
|
|
CREATE TABLE `tlanguage` (
|
2007-03-19 22:27:10 +01:00
|
|
|
`id_language` varchar(6) NOT NULL default '',
|
2007-03-12 18:58:52 +01:00
|
|
|
`name` varchar(100) NOT NULL default '',
|
2006-03-27 05:37:27 +02:00
|
|
|
PRIMARY KEY (`id_language`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2007-03-12 18:58:52 +01:00
|
|
|
|
2006-03-27 05:37:27 +02:00
|
|
|
|
|
|
|
CREATE TABLE `tlink` (
|
|
|
|
`id_link` int(10) unsigned zerofill NOT NULL auto_increment,
|
|
|
|
`name` varchar(100) NOT NULL default '',
|
|
|
|
`link` varchar(255) NOT NULL default '',
|
|
|
|
PRIMARY KEY (`id_link`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2006-03-27 05:37:27 +02:00
|
|
|
|
2007-03-12 18:58:52 +01:00
|
|
|
|
2006-03-27 05:37:27 +02:00
|
|
|
CREATE TABLE `tmensajes` (
|
2007-03-12 18:58:52 +01:00
|
|
|
`id_mensaje` bigint(20) unsigned NOT NULL auto_increment,
|
2006-03-27 05:37:27 +02:00
|
|
|
`id_usuario_origen` varchar(100) NOT NULL default '',
|
|
|
|
`id_usuario_destino` varchar(100) NOT NULL default '',
|
|
|
|
`mensaje` tinytext NOT NULL,
|
2007-04-18 19:17:06 +02:00
|
|
|
`timestamp` datetime NOT NULL default '0000-00-00 00:00:00',
|
2006-03-27 05:37:27 +02:00
|
|
|
`subject` varchar(255) NOT NULL default '',
|
|
|
|
`estado` int(10) unsigned NOT NULL default '0',
|
2007-03-12 18:58:52 +01:00
|
|
|
PRIMARY KEY (`id_mensaje`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2007-03-12 18:58:52 +01:00
|
|
|
|
2006-03-27 05:37:27 +02:00
|
|
|
|
|
|
|
CREATE TABLE `tmodule_group` (
|
2007-03-12 18:58:52 +01:00
|
|
|
`id_mg` bigint(20) unsigned NOT NULL auto_increment,
|
2006-03-27 05:37:27 +02:00
|
|
|
`name` varchar(150) NOT NULL default '',
|
|
|
|
PRIMARY KEY (`id_mg`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2007-03-12 18:58:52 +01:00
|
|
|
|
|
|
|
|
|
|
|
CREATE TABLE `tnetwork_component` (
|
|
|
|
`id_nc` mediumint(12) unsigned NOT NULL auto_increment,
|
|
|
|
`name` varchar(50) NOT NULL,
|
|
|
|
`description` varchar(250) default NULL,
|
|
|
|
`id_group` mediumint(9) NOT NULL default '1',
|
|
|
|
`type` smallint(6) NOT NULL default '6',
|
|
|
|
`max` bigint(20) NOT NULL default '0',
|
|
|
|
`min` bigint(20) NOT NULL default '0',
|
|
|
|
`module_interval` mediumint(8) unsigned NOT NULL default '0',
|
|
|
|
`tcp_port` int(10) unsigned NOT NULL default '0',
|
|
|
|
`tcp_send` varchar(255) NOT NULL,
|
|
|
|
`tcp_rcv` varchar(255) NOT NULL default 'NULL',
|
|
|
|
`snmp_community` varchar(255) NOT NULL default 'NULL',
|
|
|
|
`snmp_oid` varchar(400) NOT NULL,
|
|
|
|
`id_module_group` tinyint(4) NOT NULL default '0',
|
|
|
|
PRIMARY KEY (`id_nc`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2007-03-12 18:58:52 +01:00
|
|
|
|
|
|
|
|
|
|
|
CREATE TABLE `tnetwork_component_group` (
|
|
|
|
`id_sg` mediumint(8) unsigned NOT NULL auto_increment,
|
|
|
|
`name` varchar(200) NOT NULL default '',
|
|
|
|
`parent` mediumint(9) NOT NULL default '0',
|
|
|
|
PRIMARY KEY (`id_sg`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2007-03-12 18:58:52 +01:00
|
|
|
|
|
|
|
|
|
|
|
CREATE TABLE `tnetwork_profile` (
|
|
|
|
`id_np` mediumint(8) unsigned NOT NULL auto_increment,
|
|
|
|
`name` varchar(100) NOT NULL default '',
|
|
|
|
`description` varchar(250) default '',
|
|
|
|
PRIMARY KEY (`id_np`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2007-03-12 18:58:52 +01:00
|
|
|
|
|
|
|
|
|
|
|
CREATE TABLE `tnetwork_profile_component` (
|
|
|
|
`id_npc` mediumint(8) unsigned NOT NULL auto_increment,
|
|
|
|
`id_nc` mediumint(8) unsigned NOT NULL default '0',
|
|
|
|
`id_np` mediumint(8) unsigned NOT NULL default '0',
|
|
|
|
PRIMARY KEY (`id_npc`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2007-03-12 18:58:52 +01:00
|
|
|
|
|
|
|
|
2006-03-27 05:37:27 +02:00
|
|
|
CREATE TABLE `tnota` (
|
|
|
|
`id_nota` mediumint(8) unsigned NOT NULL auto_increment,
|
|
|
|
`id_usuario` varchar(100) NOT NULL default '0',
|
|
|
|
`timestamp` tinyblob NOT NULL,
|
|
|
|
`nota` mediumtext NOT NULL,
|
|
|
|
PRIMARY KEY (`id_nota`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2007-03-12 18:58:52 +01:00
|
|
|
|
2006-03-27 05:37:27 +02:00
|
|
|
|
|
|
|
CREATE TABLE `tnota_inc` (
|
|
|
|
`id_nota_inc` mediumint(8) unsigned NOT NULL auto_increment,
|
2007-03-12 18:58:52 +01:00
|
|
|
`id_incidencia` mediumint(9) NOT NULL default '0',
|
|
|
|
`id_nota` mediumint(9) NOT NULL default '0',
|
2006-03-27 05:37:27 +02:00
|
|
|
PRIMARY KEY (`id_nota_inc`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2007-03-12 18:58:52 +01:00
|
|
|
|
2006-03-27 05:37:27 +02:00
|
|
|
|
|
|
|
CREATE TABLE `torigen` (
|
|
|
|
`origen` varchar(100) NOT NULL default ''
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2006-03-27 05:37:27 +02:00
|
|
|
|
2007-03-12 18:58:52 +01:00
|
|
|
|
2006-03-27 05:37:27 +02:00
|
|
|
CREATE TABLE `tperfil` (
|
2007-03-12 18:58:52 +01:00
|
|
|
`id_perfil` int(10) unsigned NOT NULL auto_increment,
|
2006-03-27 05:37:27 +02:00
|
|
|
`name` varchar(60) NOT NULL default '',
|
2007-03-12 18:58:52 +01:00
|
|
|
`incident_edit` int(11) NOT NULL default '0',
|
|
|
|
`incident_view` int(11) NOT NULL default '0',
|
|
|
|
`incident_management` int(11) NOT NULL default '0',
|
|
|
|
`agent_view` int(11) NOT NULL default '0',
|
|
|
|
`agent_edit` int(11) NOT NULL default '0',
|
|
|
|
`alert_edit` int(11) NOT NULL default '0',
|
|
|
|
`user_management` int(11) NOT NULL default '0',
|
|
|
|
`db_management` int(11) NOT NULL default '0',
|
|
|
|
`alert_management` int(11) NOT NULL default '0',
|
|
|
|
`pandora_management` int(11) NOT NULL default '0',
|
2006-03-27 05:37:27 +02:00
|
|
|
PRIMARY KEY (`id_perfil`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2007-03-12 18:58:52 +01:00
|
|
|
|
2006-03-27 05:37:27 +02:00
|
|
|
|
2007-03-12 18:58:52 +01:00
|
|
|
CREATE TABLE `trecon_task` (
|
|
|
|
`id_rt` int(10) unsigned NOT NULL auto_increment,
|
|
|
|
`name` varchar(100) NOT NULL default '',
|
|
|
|
`description` varchar(250) NOT NULL default '',
|
|
|
|
`type` tinyint(3) unsigned NOT NULL default '0',
|
2007-03-28 15:08:10 +02:00
|
|
|
`subnet` varchar(64) NOT NULL default '',
|
2007-03-12 18:58:52 +01:00
|
|
|
`id_network_server` int(10) unsigned NOT NULL default '0',
|
|
|
|
`id_network_profile` int(10) unsigned NOT NULL default '0',
|
|
|
|
`create_incident` tinyint(3) unsigned NOT NULL default '0',
|
|
|
|
`id_group` int(10) unsigned NOT NULL default '1',
|
|
|
|
`utimestamp` bigint(20) unsigned NOT NULL default '0',
|
|
|
|
`status` tinyint(4) NOT NULL default '0',
|
2007-03-28 15:08:10 +02:00
|
|
|
`interval_sweep` int(10) unsigned NOT NULL default '0',
|
|
|
|
`id_network_server_assigned` int(10) unsigned NOT NULL default '0',
|
2007-03-12 18:58:52 +01:00
|
|
|
PRIMARY KEY (`id_rt`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2007-03-12 18:58:52 +01:00
|
|
|
|
|
|
|
|
2006-03-27 05:37:27 +02:00
|
|
|
CREATE TABLE `tserver` (
|
|
|
|
`id_server` int(10) unsigned NOT NULL auto_increment,
|
|
|
|
`name` varchar(100) NOT NULL default '',
|
|
|
|
`ip_address` varchar(100) NOT NULL default '',
|
2007-03-12 18:58:52 +01:00
|
|
|
`status` int(11) NOT NULL default '0',
|
2006-03-27 05:37:27 +02:00
|
|
|
`laststart` datetime NOT NULL default '0000-00-00 00:00:00',
|
|
|
|
`keepalive` datetime NOT NULL default '0000-00-00 00:00:00',
|
2007-03-12 18:58:52 +01:00
|
|
|
`snmp_server` tinyint(3) unsigned NOT NULL default '0',
|
|
|
|
`network_server` tinyint(3) unsigned NOT NULL default '0',
|
|
|
|
`data_server` tinyint(3) unsigned NOT NULL default '0',
|
|
|
|
`master` tinyint(3) unsigned NOT NULL default '0',
|
|
|
|
`checksum` tinyint(3) unsigned NOT NULL default '0',
|
|
|
|
`description` varchar(255) default NULL,
|
|
|
|
`recon_server` tinyint(3) unsigned NOT NULL default '0',
|
2007-03-28 15:08:10 +02:00
|
|
|
`version` varchar(20) NOT NULL default '',
|
2006-03-27 05:37:27 +02:00
|
|
|
PRIMARY KEY (`id_server`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2006-03-27 05:37:27 +02:00
|
|
|
|
2007-03-12 18:58:52 +01:00
|
|
|
|
2006-03-27 05:37:27 +02:00
|
|
|
CREATE TABLE `tsesion` (
|
|
|
|
`ID_sesion` bigint(4) unsigned NOT NULL auto_increment,
|
|
|
|
`ID_usuario` varchar(60) NOT NULL default '0',
|
|
|
|
`IP_origen` varchar(100) NOT NULL default '',
|
|
|
|
`accion` varchar(100) NOT NULL default '',
|
|
|
|
`descripcion` varchar(200) NOT NULL default '',
|
|
|
|
`fecha` datetime NOT NULL default '0000-00-00 00:00:00',
|
2007-03-28 15:08:10 +02:00
|
|
|
`utimestamp` bigint(20) unsigned NOT NULL default '0',
|
2006-03-27 05:37:27 +02:00
|
|
|
PRIMARY KEY (`ID_sesion`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2007-03-12 18:58:52 +01:00
|
|
|
|
2006-03-27 05:37:27 +02:00
|
|
|
|
|
|
|
CREATE TABLE `ttipo_modulo` (
|
|
|
|
`id_tipo` smallint(5) unsigned NOT NULL auto_increment,
|
|
|
|
`nombre` varchar(100) NOT NULL default '',
|
2007-03-12 18:58:52 +01:00
|
|
|
`categoria` int(11) NOT NULL default '0',
|
2006-03-27 05:37:27 +02:00
|
|
|
`descripcion` varchar(100) NOT NULL default '',
|
|
|
|
`icon` varchar(100) default NULL,
|
|
|
|
PRIMARY KEY (`id_tipo`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2007-03-12 18:58:52 +01:00
|
|
|
|
2006-03-27 05:37:27 +02:00
|
|
|
|
|
|
|
CREATE TABLE `ttrap` (
|
2007-03-12 18:58:52 +01:00
|
|
|
`id_trap` bigint(20) unsigned NOT NULL auto_increment,
|
2006-03-27 05:37:27 +02:00
|
|
|
`source` varchar(50) NOT NULL default '',
|
|
|
|
`oid` varchar(255) NOT NULL default '',
|
|
|
|
`oid_custom` varchar(255) default '',
|
2007-03-12 18:58:52 +01:00
|
|
|
`type` int(11) NOT NULL default '0',
|
2006-03-27 05:37:27 +02:00
|
|
|
`type_custom` varchar(100) default '',
|
|
|
|
`value` varchar(255) default '',
|
|
|
|
`value_custom` varchar(255) default '',
|
2007-03-12 18:58:52 +01:00
|
|
|
`alerted` smallint(6) NOT NULL default '0',
|
|
|
|
`status` smallint(6) NOT NULL default '0',
|
2006-03-27 05:37:27 +02:00
|
|
|
`id_usuario` varchar(150) default '',
|
|
|
|
`timestamp` datetime NOT NULL default '0000-00-00 00:00:00',
|
|
|
|
PRIMARY KEY (`id_trap`)
|
2007-04-18 11:58:26 +02:00
|
|
|
) ENGINE=InnoDB;
|
2006-03-27 05:37:27 +02:00
|
|
|
|
2007-03-12 18:58:52 +01:00
|
|
|
|
2006-03-27 05:37:27 +02:00
|
|
|
CREATE TABLE `tusuario` (
|
|
|
|
`id_usuario` varchar(60) NOT NULL default '0',
|
|
|
|
`nombre_real` varchar(125) NOT NULL default '',
|
|
|
|
`password` varchar(45) default NULL,
|
|
|
|
`comentarios` varchar(200) default NULL,
|
|
|
|
`fecha_registro` datetime NOT NULL default '0000-00-00 00:00:00',
|
|
|
|
`direccion` varchar(100) default '',
|
|
|
|
`telefono` varchar(100) default '',
|
|
|
|
`nivel` tinyint(1) NOT NULL default '0'
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2007-03-12 18:58:52 +01:00
|
|
|
|
2006-03-27 05:37:27 +02:00
|
|
|
|
|
|
|
CREATE TABLE `tusuario_perfil` (
|
2007-03-12 18:58:52 +01:00
|
|
|
`id_up` bigint(20) unsigned NOT NULL auto_increment,
|
2006-03-27 05:37:27 +02:00
|
|
|
`id_usuario` varchar(100) NOT NULL default '',
|
2007-03-12 18:58:52 +01:00
|
|
|
`id_perfil` int(20) NOT NULL default '0',
|
|
|
|
`id_grupo` int(11) NOT NULL default '0',
|
2006-03-27 05:37:27 +02:00
|
|
|
`assigned_by` varchar(100) NOT NULL default '',
|
|
|
|
PRIMARY KEY (`id_up`)
|
2007-03-28 16:51:39 +02:00
|
|
|
) ENGINE=InnoDB;
|
2007-03-12 18:58:52 +01:00
|
|
|
|
2007-04-13 20:47:58 +02:00
|
|
|
|
|
|
|
CREATE TABLE `tnews` (
|
|
|
|
`id_news` INTEGER UNSIGNED NOT NULL AUTO_INCREMENT,
|
|
|
|
`author` varchar(255) NOT NULL DEFAULT '',
|
|
|
|
`subject` varchar(255) NOT NULL DEFAULT '',
|
2007-04-18 19:17:06 +02:00
|
|
|
`text` TEXT NOT NULL,
|
2007-06-08 17:55:53 +02:00
|
|
|
`timestamp` DATETIME NOT NULL DEFAULT 0,
|
2007-04-13 20:47:58 +02:00
|
|
|
PRIMARY KEY(`id_news`)
|
2007-04-19 20:50:07 +02:00
|
|
|
) ENGINE = InnoDB;
|
|
|
|
|
|
|
|
CREATE TABLE `tgraph` (
|
|
|
|
`id_graph` INTEGER UNSIGNED NOT NULL AUTO_INCREMENT,
|
|
|
|
`id_user` varchar(100) NOT NULL default '',
|
|
|
|
`name` varchar(150) NOT NULL default '',
|
|
|
|
`description` TEXT NOT NULL,
|
|
|
|
`period` int(11) NOT NULL default '0',
|
|
|
|
`width` smallint(5) UNSIGNED NOT NULL DEFAULT 0,
|
|
|
|
`height` smallint(5) UNSIGNED NOT NULL DEFAULT 0,
|
|
|
|
`private` tinyint(1) UNSIGNED NOT NULL default 0,
|
|
|
|
`events` tinyint(1) UNSIGNED NOT NULL default 0,
|
|
|
|
PRIMARY KEY(`id_graph`)
|
|
|
|
) ENGINE = InnoDB;
|
|
|
|
|
|
|
|
CREATE TABLE `tgraph_source` (
|
|
|
|
`id_gs` INTEGER UNSIGNED NOT NULL AUTO_INCREMENT,
|
|
|
|
`id_graph` int(11) NOT NULL default 0,
|
|
|
|
`id_agent_module` int(11) NOT NULL default 0,
|
|
|
|
`weight` smallint(5) UNSIGNED NOT NULL DEFAULT 0,
|
|
|
|
PRIMARY KEY(`id_gs`)
|
|
|
|
) ENGINE = InnoDB;
|
|
|
|
|
|
|
|
|
|
|
|
CREATE TABLE `treport` (
|
|
|
|
`id_report` INTEGER UNSIGNED NOT NULL AUTO_INCREMENT,
|
|
|
|
`id_user` varchar(100) NOT NULL default '',
|
|
|
|
`name` varchar(150) NOT NULL default '',
|
|
|
|
`description` TEXT NOT NULL,
|
|
|
|
`private` tinyint(1) UNSIGNED NOT NULL default 0,
|
|
|
|
PRIMARY KEY(`id_report`)
|
|
|
|
) ENGINE = InnoDB;
|
|
|
|
|
|
|
|
CREATE TABLE `treport_content` (
|
|
|
|
`id_rc` INTEGER UNSIGNED NOT NULL AUTO_INCREMENT,
|
|
|
|
`id_report` INTEGER UNSIGNED NOT NULL default 0,
|
|
|
|
`id_gs` INTEGER UNSIGNED NOT NULL default 0,
|
|
|
|
`id_agent_module` int(11) NOT NULL default 0,
|
|
|
|
`type` tinyint(1) UNSIGNED NOT NULL default 0,
|
|
|
|
`period` int(11) NOT NULL default 0,
|
2007-06-07 19:46:38 +02:00
|
|
|
`sla_max` int(11) NOT NULL default 0,
|
|
|
|
`sla_min` int(11) NOT NULL default 0,
|
|
|
|
`sla_limit` int(11) NOT NULL default 0,
|
2007-04-19 20:50:07 +02:00
|
|
|
PRIMARY KEY(`id_rc`)
|
|
|
|
) ENGINE = InnoDB;
|
|
|
|
|
2007-06-07 19:46:38 +02:00
|
|
|
/*
|
|
|
|
|
|
|
|
treport_content descripcion
|
|
|
|
type valid values
|
|
|
|
0 - Simple graph
|
|
|
|
1 - User/Combined graph
|
|
|
|
2 - SLA
|
|
|
|
3 - Event report
|
|
|
|
4 - Alert report
|
|
|
|
5 - Monitor report
|
|
|
|
6 - Avg. value
|
|
|
|
7 - Max. value
|
|
|
|
8 - Min. value
|
|
|
|
|
|
|
|
id_gs is for combined graph pprimary key id
|
|
|
|
|
|
|
|
*/
|
|
|
|
|
2007-05-20 19:12:31 +02:00
|
|
|
CREATE TABLE `tlayout` (
|
|
|
|
`id` INTEGER UNSIGNED NOT NULL AUTO_INCREMENT,
|
|
|
|
`name` varchar(50) NOT NULL,
|
|
|
|
`id_group` INTEGER UNSIGNED NOT NULL,
|
|
|
|
`background` varchar(200) NOT NULL,
|
|
|
|
`fullscreen` tinyint(1) UNSIGNED NOT NULL default 0,
|
|
|
|
`height` INTEGER UNSIGNED NOT NULL default 0,
|
|
|
|
`width` INTEGER UNSIGNED NOT NULL default 0,
|
|
|
|
PRIMARY KEY(`id`)
|
|
|
|
) ENGINE = InnoDB;
|
|
|
|
|
|
|
|
CREATE TABLE `tlayout_data` (
|
|
|
|
`id` INTEGER UNSIGNED NOT NULL AUTO_INCREMENT,
|
|
|
|
`id_layout` INTEGER UNSIGNED NOT NULL default 0,
|
|
|
|
`pos_x` INTEGER UNSIGNED NOT NULL default 0,
|
|
|
|
`pos_y` INTEGER UNSIGNED NOT NULL default 0,
|
|
|
|
`height` INTEGER UNSIGNED NOT NULL default 0,
|
|
|
|
`width` INTEGER UNSIGNED NOT NULL default 0,
|
|
|
|
`label` varchar(200) DEFAULT "",
|
|
|
|
`image` varchar(200) DEFAULT "",
|
|
|
|
`type` tinyint(1) UNSIGNED NOT NULL default 0,
|
|
|
|
`period` INTEGER UNSIGNED NOT NULL default 3600,
|
|
|
|
`id_agente_modulo` mediumint(8) unsigned NOT NULL default '0',
|
|
|
|
`id_layout_linked` INTEGER unsigned NOT NULL default '0',
|
|
|
|
`parent_item` INTEGER UNSIGNED NOT NULL default 0,
|
|
|
|
`label_color` varchar(20) DEFAULT "",
|
2007-05-23 08:11:08 +02:00
|
|
|
`no_link_color` tinyint(1) UNSIGNED NOT NULL default 0,
|
2007-05-20 19:12:31 +02:00
|
|
|
PRIMARY KEY(`id`)
|
|
|
|
) ENGINE = InnoDB;
|