2012-01-09 Vanessa Gil <vanessa.gil@artica.es>
* pandoradb.oracle.sql pandoradb.postgreSQL.sql extras/pandoradb_migrate_4.0.x_to_4.1.mysql.sql extras/pandoradb_migrate_4.0.x_to_4.1.oracle.sql extras/pandoradb_migrate_4.0.x_to_4.1.postgreSQL.sql: Added migration script for 4.1 version. git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@5329 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
52cbe26e63
commit
6c789d6a03
|
@ -1,3 +1,11 @@
|
|||
2012-01-09 Vanessa Gil <vanessa.gil@artica.es>
|
||||
* pandoradb.oracle.sql
|
||||
pandoradb.postgreSQL.sql
|
||||
extras/pandoradb_migrate_4.0.x_to_4.1.mysql.sql
|
||||
extras/pandoradb_migrate_4.0.x_to_4.1.oracle.sql
|
||||
extras/pandoradb_migrate_4.0.x_to_4.1.postgreSQL.sql: Added migration
|
||||
script for 4.1 version.
|
||||
|
||||
2012-01-09 Vanessa Gil <vanessa.gil@artica.es>
|
||||
* godmode/netflow/nf_item_list.php
|
||||
godmode/netflow/nf_report_item.php
|
||||
|
|
|
@ -30,19 +30,6 @@ CREATE TABLE IF NOT EXISTS `tnetflow_report` (
|
|||
PRIMARY KEY(`id_report`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
||||
|
||||
-- -----------------------------------------------------
|
||||
-- Table `tnetflow_options`
|
||||
-- -----------------------------------------------------
|
||||
|
||||
CREATE TABLE IF NOT EXISTS `tnetflow_options` (
|
||||
`id_option` int(10) unsigned NOT NULL auto_increment,
|
||||
`id_name` varchar(60) NOT NULL default '0',
|
||||
`description` TEXT NOT NULL default '',
|
||||
`path` varchar(200),
|
||||
`port` varchar(100),
|
||||
PRIMARY KEY (`id_option`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
||||
|
||||
-- -----------------------------------------------------
|
||||
-- Table `tnetflow_report_content`
|
||||
-- -----------------------------------------------------
|
||||
|
@ -50,14 +37,16 @@ PRIMARY KEY (`id_option`)
|
|||
CREATE TABLE IF NOT EXISTS `tnetflow_report_content` (
|
||||
`id_rc` INTEGER UNSIGNED NOT NULL AUTO_INCREMENT,
|
||||
`id_report` INTEGER UNSIGNED NOT NULL default 0,
|
||||
`id_filter` varchar(60),
|
||||
`id_filter` INTEGER UNSIGNED NOT NULL default 0,
|
||||
`date` bigint(20) NOT NULL default '0',
|
||||
`period` int(11) NOT NULL default 0,
|
||||
`max` int (11) NOT NULL default 0,
|
||||
`show_graph` varchar(60),
|
||||
PRIMARY KEY(`id_rc`),
|
||||
FOREIGN KEY (`id_report`) REFERENCES tnetflow_report(`id_report`)
|
||||
ON UPDATE CASCADE ON DELETE CASCADE
|
||||
ON UPDATE CASCADE ON DELETE CASCADE,
|
||||
FOREIGN KEY (`id_filter`) REFERENCES tnetflow_filter(`id_sg`)
|
||||
ON DELETE CASCADE
|
||||
) ENGINE = InnoDB DEFAULT CHARSET=utf8;
|
||||
|
||||
-- -----------------------------------------------------
|
||||
|
|
|
@ -3,3 +3,34 @@
|
|||
-- -----------------------------------------------------
|
||||
|
||||
alter table tusuario add (disabled NUMBER(10,0) default 0 NOT NULL);
|
||||
|
||||
-- -----------------------------------------------------
|
||||
-- Table "tnetflow_report"
|
||||
-- -----------------------------------------------------
|
||||
|
||||
CREATE TABLE tnetflow_report (
|
||||
id_report NUMBER(10, 0) NOT NULL PRIMARY KEY,
|
||||
id_name VARCHAR2(100) NOT NULL,
|
||||
description CLOB default '',
|
||||
"group" VARCHAR2(50)
|
||||
);
|
||||
|
||||
CREATE SEQUENCE tnetflow_report_s INCREMENT BY 1 START WITH 1;
|
||||
CREATE OR REPLACE TRIGGER tnetflow_report_inc BEFORE INSERT ON tnetflow_report REFERENCING NEW AS NEW FOR EACH ROW BEGIN SELECT tnetflow_report_s.nextval INTO :NEW.ID_REPORT FROM dual; END tnetflow_report_inc;;
|
||||
|
||||
-- -----------------------------------------------------
|
||||
-- Table "tnetflow_report_content"
|
||||
-- -----------------------------------------------------
|
||||
|
||||
CREATE TABLE tnetflow_report_content (
|
||||
id_rc NUMBER(10, 0) NOT NULL PRIMARY KEY,
|
||||
id_report NUMBER(10, 0) NOT NULL REFERENCES tnetflow_report(id_report) ON DELETE CASCADE,
|
||||
id_filter NUMBER(10,0) NOT NULL REFERENCES tnetflow_filter(id_sg) ON DELETE CASCADE,
|
||||
"date" NUMBER(20, 0) default 0 NOT NULL,
|
||||
period NUMBER(11, 0) default 0 NOT NULL,
|
||||
max NUMBER(11, 0) default 0 NOT NULL,
|
||||
show_graph VARCHAR2(60)
|
||||
);
|
||||
|
||||
CREATE SEQUENCE tnetflow_report_content_s INCREMENT BY 1 START WITH 1;
|
||||
CREATE OR REPLACE TRIGGER tnetflow_report_content_inc BEFORE INSERT ON tnetflow_report_content REFERENCING NEW AS NEW FOR EACH ROW BEGIN SELECT tnetflow_report_content_s.nextval INTO :NEW.ID_RC FROM dual; END tnetflow_report_content_inc;;
|
||||
|
|
|
@ -3,3 +3,45 @@
|
|||
-- -----------------------------------------------------
|
||||
|
||||
ALTER TABLE "tusuario" ADD COLUMN "disabled" INTEGER NOT NULL DEFAULT 0;
|
||||
|
||||
-- -----------------------------------------------------
|
||||
-- Table `tnetflow_filter`
|
||||
-- -----------------------------------------------------
|
||||
CREATE TABLE "tnetflow_filter" (
|
||||
"id_sg" SERIAL NOT NULL PRIMARY KEY,
|
||||
"id_name" varchar(60) NOT NULL default '',
|
||||
"group" varchar(60),
|
||||
"ip_dst" varchar(100),
|
||||
"ip_src" varchar(100),
|
||||
"dst_port" varchar(100),
|
||||
"src_port" varchar(100),
|
||||
"aggregate" varchar(60),
|
||||
"show_packets" SMALLINT default 0,
|
||||
"show_bytes" SMALLINT default 0,
|
||||
"show_bps" SMALLINT default 0,
|
||||
"show_bpp" SMALLINT default 0
|
||||
);
|
||||
|
||||
-- -----------------------------------------------------
|
||||
-- Table `tnetflow_report`
|
||||
-- -----------------------------------------------------
|
||||
CREATE TABLE "tnetflow_report" (
|
||||
"id_report" SERIAL NOT NULL PRIMARY KEY,
|
||||
"id_name" varchar(150) NOT NULL default '',
|
||||
"description" TEXT,
|
||||
"group" varchar(60)
|
||||
);
|
||||
|
||||
-- -----------------------------------------------------
|
||||
-- Table `tnetflow_report_content`
|
||||
-- -----------------------------------------------------
|
||||
CREATE TABLE "tnetflow_report_content" (
|
||||
"id_rc" SERIAL NOT NULL PRIMARY KEY,
|
||||
"id_report" INTEGER NOT NULL default 0 REFERENCES tnetflow_report("id_report") ON DELETE CASCADE,
|
||||
"id_filter" INTEGER NOT NULL default 0 REFERENCES tnetflow_filter("id_sg") ON DELETE CASCADE,
|
||||
"date" BIGINT NOT NULL default 0,
|
||||
"period" INTEGER NOT NULL default 0,
|
||||
"max" INTEGER NOT NULL default 0,
|
||||
"show_graph" varchar(60)
|
||||
);
|
||||
|
||||
|
|
|
@ -1519,7 +1519,7 @@ CREATE OR REPLACE TRIGGER tnetflow_report_inc BEFORE INSERT ON tnetflow_report R
|
|||
CREATE TABLE tnetflow_report_content (
|
||||
id_rc NUMBER(10, 0) NOT NULL PRIMARY KEY,
|
||||
id_report NUMBER(10, 0) NOT NULL REFERENCES tnetflow_report(id_report) ON DELETE CASCADE,
|
||||
id_filter VARCHAR2(100),
|
||||
id_filter NUMBER(10,0) NOT NULL REFERENCES tnetflow_filter(id_sg) ON DELETE CASCADE,
|
||||
"date" NUMBER(20, 0) default 0 NOT NULL,
|
||||
period NUMBER(11, 0) default 0 NOT NULL,
|
||||
max NUMBER(11, 0) default 0 NOT NULL,
|
||||
|
|
|
@ -1189,3 +1189,44 @@ CREATE TABLE "ttag_event" (
|
|||
);
|
||||
|
||||
CREATE INDEX "ttag_event_id_evento_idx" ON "ttag_event"("id_evento");
|
||||
|
||||
-- -----------------------------------------------------
|
||||
-- Table `tnetflow_filter`
|
||||
-- -----------------------------------------------------
|
||||
CREATE TABLE "tnetflow_filter" (
|
||||
"id_sg" SERIAL NOT NULL PRIMARY KEY,
|
||||
"id_name" varchar(60) NOT NULL default '',
|
||||
"group" varchar(60),
|
||||
"ip_dst" varchar(100),
|
||||
"ip_src" varchar(100),
|
||||
"dst_port" varchar(100),
|
||||
"src_port" varchar(100),
|
||||
"aggregate" varchar(60),
|
||||
"show_packets" SMALLINT default 0,
|
||||
"show_bytes" SMALLINT default 0,
|
||||
"show_bps" SMALLINT default 0,
|
||||
"show_bpp" SMALLINT default 0
|
||||
);
|
||||
|
||||
-- -----------------------------------------------------
|
||||
-- Table `tnetflow_report`
|
||||
-- -----------------------------------------------------
|
||||
CREATE TABLE "tnetflow_report" (
|
||||
"id_report" SERIAL NOT NULL PRIMARY KEY,
|
||||
"id_name" varchar(150) NOT NULL default '',
|
||||
"description" TEXT,
|
||||
"group" varchar(60)
|
||||
);
|
||||
|
||||
-- -----------------------------------------------------
|
||||
-- Table `tnetflow_report_content`
|
||||
-- -----------------------------------------------------
|
||||
CREATE TABLE "tnetflow_report_content" (
|
||||
"id_rc" SERIAL NOT NULL PRIMARY KEY,
|
||||
"id_report" INTEGER NOT NULL default 0 REFERENCES tnetflow_report("id_report") ON DELETE CASCADE,
|
||||
"id_filter" INTEGER NOT NULL default 0 REFERENCES tnetflow_filter("id_sg") ON DELETE CASCADE,
|
||||
"date" BIGINT NOT NULL default 0,
|
||||
"period" INTEGER NOT NULL default 0,
|
||||
"max" INTEGER NOT NULL default 0,
|
||||
"show_graph" varchar(60)
|
||||
);
|
||||
|
|
Loading…
Reference in New Issue