Module: sip-router
Branch: kamailio_3.0
Commit: 0586447a736900832b116f3a3826ba01d9969b6a
URL:
http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=0586447…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: Mon Dec 14 10:22:25 2009 +0100
dbschema: regenerate db creation scripts
- get the updates to permissions and lcr tables
---
utils/kamctl/db_berkeley/kamailio/version | 2 +-
utils/kamctl/dbtext/kamailio/version | 2 +-
utils/kamctl/mysql/lcr-create.sql | 3 ++-
utils/kamctl/mysql/permissions-create.sql | 4 ++--
utils/kamctl/oracle/lcr-create.sql | 3 ++-
utils/kamctl/oracle/permissions-create.sql | 4 ++--
utils/kamctl/postgres/lcr-create.sql | 3 ++-
utils/kamctl/postgres/permissions-create.sql | 4 ++--
8 files changed, 14 insertions(+), 11 deletions(-)
diff --git a/utils/kamctl/db_berkeley/kamailio/version
b/utils/kamctl/db_berkeley/kamailio/version
index d977706..e03028f 100644
--- a/utils/kamctl/db_berkeley/kamailio/version
+++ b/utils/kamctl/db_berkeley/kamailio/version
@@ -79,7 +79,7 @@ speed_dial|2
subscriber|
subscriber|6
trusted|
-trusted|4
+trusted|5
uri|
uri|1
userblacklist|
diff --git a/utils/kamctl/dbtext/kamailio/version b/utils/kamctl/dbtext/kamailio/version
index 2822a7a..5b9b49d 100644
--- a/utils/kamctl/dbtext/kamailio/version
+++ b/utils/kamctl/dbtext/kamailio/version
@@ -34,7 +34,7 @@ silo:5
sip_trace:2
speed_dial:2
subscriber:6
-trusted:4
+trusted:5
uri:1
userblacklist:1
usr_preferences:2
diff --git a/utils/kamctl/mysql/lcr-create.sql b/utils/kamctl/mysql/lcr-create.sql
index 1c6db01..63d72be 100644
--- a/utils/kamctl/mysql/lcr-create.sql
+++ b/utils/kamctl/mysql/lcr-create.sql
@@ -14,7 +14,8 @@ CREATE TABLE gw (
weight INT UNSIGNED,
flags INT UNSIGNED DEFAULT 0 NOT NULL,
defunct INT UNSIGNED DEFAULT NULL,
- CONSTRAINT lcr_id_gw_name_idx UNIQUE (lcr_id, gw_name)
+ CONSTRAINT lcr_id_grp_id_gw_name_idx UNIQUE (lcr_id, grp_id, gw_name),
+ CONSTRAINT lcr_id_grp_id_ip_addr_idx UNIQUE (lcr_id, grp_id, ip_addr)
) ENGINE=MyISAM;
INSERT INTO version (table_name, table_version) values ('lcr','3');
diff --git a/utils/kamctl/mysql/permissions-create.sql
b/utils/kamctl/mysql/permissions-create.sql
index ecc92e8..f3be981 100644
--- a/utils/kamctl/mysql/permissions-create.sql
+++ b/utils/kamctl/mysql/permissions-create.sql
@@ -1,10 +1,10 @@
-INSERT INTO version (table_name, table_version) values ('trusted','4');
+INSERT INTO version (table_name, table_version) values ('trusted','5');
CREATE TABLE trusted (
id INT(10) UNSIGNED AUTO_INCREMENT PRIMARY KEY NOT NULL,
src_ip VARCHAR(50) NOT NULL,
proto VARCHAR(4) NOT NULL,
from_pattern VARCHAR(64) DEFAULT NULL,
- tag VARCHAR(32)
+ tag VARCHAR(64)
) ENGINE=MyISAM;
CREATE INDEX peer_idx ON trusted (src_ip);
diff --git a/utils/kamctl/oracle/lcr-create.sql b/utils/kamctl/oracle/lcr-create.sql
index 1dc954a..075af32 100644
--- a/utils/kamctl/oracle/lcr-create.sql
+++ b/utils/kamctl/oracle/lcr-create.sql
@@ -14,7 +14,8 @@ CREATE TABLE gw (
weight NUMBER(10),
flags NUMBER(10) DEFAULT 0 NOT NULL,
defunct NUMBER(10) DEFAULT NULL,
- CONSTRAINT gw_lcr_id_gw_name_idx UNIQUE (lcr_id, gw_name)
+ CONSTRAINT gw_lcr_id_grp_id_gw_name_idx UNIQUE (lcr_id, grp_id, gw_name),
+ CONSTRAINT gw_lcr_id_grp_id_ip_addr_idx UNIQUE (lcr_id, grp_id, ip_addr)
);
CREATE OR REPLACE TRIGGER gw_tr
diff --git a/utils/kamctl/oracle/permissions-create.sql
b/utils/kamctl/oracle/permissions-create.sql
index 4153147..c6045d0 100644
--- a/utils/kamctl/oracle/permissions-create.sql
+++ b/utils/kamctl/oracle/permissions-create.sql
@@ -1,10 +1,10 @@
-INSERT INTO version (table_name, table_version) values ('trusted','4');
+INSERT INTO version (table_name, table_version) values ('trusted','5');
CREATE TABLE trusted (
id NUMBER(10) PRIMARY KEY,
src_ip VARCHAR2(50),
proto VARCHAR2(4),
from_pattern VARCHAR2(64) DEFAULT NULL,
- tag VARCHAR2(32)
+ tag VARCHAR2(64)
);
CREATE OR REPLACE TRIGGER trusted_tr
diff --git a/utils/kamctl/postgres/lcr-create.sql b/utils/kamctl/postgres/lcr-create.sql
index 834ea08..e23e7f7 100644
--- a/utils/kamctl/postgres/lcr-create.sql
+++ b/utils/kamctl/postgres/lcr-create.sql
@@ -14,7 +14,8 @@ CREATE TABLE gw (
weight INTEGER,
flags INTEGER DEFAULT 0 NOT NULL,
defunct INTEGER DEFAULT NULL,
- CONSTRAINT gw_lcr_id_gw_name_idx UNIQUE (lcr_id, gw_name)
+ CONSTRAINT gw_lcr_id_grp_id_gw_name_idx UNIQUE (lcr_id, grp_id, gw_name),
+ CONSTRAINT gw_lcr_id_grp_id_ip_addr_idx UNIQUE (lcr_id, grp_id, ip_addr)
);
INSERT INTO version (table_name, table_version) values ('lcr','3');
diff --git a/utils/kamctl/postgres/permissions-create.sql
b/utils/kamctl/postgres/permissions-create.sql
index 886ec12..5514ef5 100644
--- a/utils/kamctl/postgres/permissions-create.sql
+++ b/utils/kamctl/postgres/permissions-create.sql
@@ -1,10 +1,10 @@
-INSERT INTO version (table_name, table_version) values ('trusted','4');
+INSERT INTO version (table_name, table_version) values ('trusted','5');
CREATE TABLE trusted (
id SERIAL PRIMARY KEY NOT NULL,
src_ip VARCHAR(50) NOT NULL,
proto VARCHAR(4) NOT NULL,
from_pattern VARCHAR(64) DEFAULT NULL,
- tag VARCHAR(32)
+ tag VARCHAR(64)
);
CREATE INDEX trusted_peer_idx ON trusted (src_ip);