Add database changes
This commit is contained in:
parent
5e039adb26
commit
a1bd93bac7
|
@ -0,0 +1,9 @@
|
|||
START TRANSACTION;
|
||||
|
||||
ALTER TABLE `talert_templates` ADD COLUMN `previous_name` text;
|
||||
ALTER TABLE `talert_actions` ADD COLUMN `previous_name` text;
|
||||
ALTER TABLE `talert_commands` ADD COLUMN `previous_name` text;
|
||||
ALTER TABLE `ttag` ADD COLUMN `previous_name` text default '';
|
||||
ALTER TABLE `tconfig_os` ADD COLUMN `previous_name` text default '';
|
||||
|
||||
COMMIT;
|
|
@ -1311,6 +1311,8 @@ ALTER TABLE talert_actions ADD COLUMN `field12_recovery` TEXT NOT NULL DEFAULT "
|
|||
ALTER TABLE talert_actions ADD COLUMN `field13_recovery` TEXT NOT NULL DEFAULT "";
|
||||
ALTER TABLE talert_actions ADD COLUMN `field14_recovery` TEXT NOT NULL DEFAULT "";
|
||||
ALTER TABLE talert_actions ADD COLUMN `field15_recovery` TEXT NOT NULL DEFAULT "";
|
||||
ALTER TABLE `talert_actions` ADD COLUMN `previous_name` text;
|
||||
|
||||
ALTER TABLE `talert_actions` MODIFY COLUMN `field11` text NOT NULL,
|
||||
MODIFY COLUMN `field12` text NOT NULL,
|
||||
MODIFY COLUMN `field13` text NOT NULL,
|
||||
|
@ -1324,6 +1326,7 @@ UPDATE `talert_commands` SET `fields_descriptions` = '[\"Integria IMS 
|
|||
UPDATE `talert_commands` SET `description` = 'This alert send an email using internal Pandora FMS Server SMTP capabilities (defined in each server, using:
_field1_ as destination email address, and
_field2_ as subject for message. 
_field3_ as text of message. 
_field4_ as content type (text/plain or html/text).', `fields_descriptions` = '[\"Destination address\",\"Subject\",\"Text\",\"Content Type\",\"\",\"\",\"\",\"\",\"\",\"\"]', `fields_values` = '[\"\",\"\",\"_html_editor_\",\"_content_type_\",\"\",\"\",\"\",\"\",\"\",\"\"]' WHERE id=1;
|
||||
ALTER TABLE `talert_commands` ADD COLUMN `id_group` mediumint(8) unsigned NULL default 0;
|
||||
ALTER TABLE `talert_commands` ADD COLUMN `fields_hidden` text;
|
||||
ALTER TABLE `talert_commands` ADD COLUMN `previous_name` text;
|
||||
|
||||
UPDATE `talert_actions` SET `field4` = 'text/html', `field4_recovery` = 'text/html' WHERE id = 1;
|
||||
|
||||
|
@ -1336,6 +1339,11 @@ ALTER TABLE `talert_commands` MODIFY COLUMN `id_group` mediumint(8) unsigned NUL
|
|||
-- ---------------------------------------------------------------------
|
||||
ALTER TABLE `tmap` MODIFY COLUMN `id_user` varchar(250) NOT NULL DEFAULT '';
|
||||
|
||||
-- ---------------------------------------------------------------------
|
||||
-- Table `ttag`
|
||||
-- ---------------------------------------------------------------------
|
||||
ALTER TABLE `ttag` ADD COLUMN `previous_name` text default '';
|
||||
|
||||
-- ---------------------------------------------------------------------
|
||||
-- Table `tconfig`
|
||||
-- ---------------------------------------------------------------------
|
||||
|
@ -1380,6 +1388,8 @@ INSERT INTO `tconfig` (`token`, `value`) VALUES ('cr_incident_content', '');
|
|||
-- Table `tconfig_os`
|
||||
-- ---------------------------------------------------------------------
|
||||
|
||||
ALTER TABLE `tconfig_os` ADD COLUMN `previous_name` text default '';
|
||||
|
||||
INSERT INTO `tconfig_os` (`id_os`, `name`, `description`, `icon_name`) VALUES (100, 'Cluster', 'Cluster agent', 'so_cluster.png');
|
||||
|
||||
UPDATE `tagente` SET `id_os` = 100 WHERE `id_os` = 21 and (select `id_os` from `tconfig_os` WHERE `id_os` = 21 and `name` = 'Cluster');
|
||||
|
@ -2451,6 +2461,8 @@ INSERT INTO `tnews` (`id_news`, `author`, `subject`, `text`, `timestamp`) VALUES
|
|||
-- Alter table `talert_templates`
|
||||
-- ----------------------------------------------------------------------
|
||||
|
||||
ALTER TABLE `talert_templates` ADD COLUMN `previous_name` text;
|
||||
|
||||
ALTER TABLE `talert_templates` MODIFY COLUMN `type` ENUM('regex','max_min','max','min','equal','not_equal','warning','critical','onchange','unknown','always','not_normal');
|
||||
|
||||
ALTER TABLE `talert_templates` MODIFY COLUMN `field11` text NOT NULL,
|
||||
|
|
|
@ -374,6 +374,7 @@ CREATE TABLE IF NOT EXISTS `talert_snmp` (
|
|||
CREATE TABLE IF NOT EXISTS `talert_commands` (
|
||||
`id` int(10) unsigned NOT NULL auto_increment,
|
||||
`name` varchar(100) NOT NULL default '',
|
||||
`previous_name` text,
|
||||
`command` text,
|
||||
`id_group` mediumint(8) unsigned NULL default 0,
|
||||
`description` text,
|
||||
|
@ -390,6 +391,7 @@ CREATE TABLE IF NOT EXISTS `talert_commands` (
|
|||
CREATE TABLE IF NOT EXISTS `talert_actions` (
|
||||
`id` int(10) unsigned NOT NULL auto_increment,
|
||||
`name` text,
|
||||
`previous_name` text,
|
||||
`id_alert_command` int(10) unsigned NULL default 0,
|
||||
`field1` text NOT NULL,
|
||||
`field2` text NOT NULL,
|
||||
|
@ -434,6 +436,7 @@ CREATE TABLE IF NOT EXISTS `talert_actions` (
|
|||
CREATE TABLE IF NOT EXISTS `talert_templates` (
|
||||
`id` int(10) unsigned NOT NULL auto_increment,
|
||||
`name` text,
|
||||
`previous_name` text,
|
||||
`description` mediumtext,
|
||||
`id_alert_action` int(10) unsigned NULL,
|
||||
`field1` text NOT NULL,
|
||||
|
@ -583,6 +586,7 @@ CREATE TABLE IF NOT EXISTS `tconfig_os` (
|
|||
`name` varchar(100) NOT NULL default '',
|
||||
`description` varchar(250) default '',
|
||||
`icon_name` varchar(100) default '',
|
||||
`previous_name` text default '',
|
||||
PRIMARY KEY (`id_os`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
||||
|
||||
|
|
Loading…
Reference in New Issue