summaryrefslogtreecommitdiffstats
path: root/upgrades/dbpatches
diff options
context:
space:
mode:
authoralex <alex@97f52cf1-0a1b-0410-bd0e-c28be96e8082>2008-03-11 14:11:01 +0000
committeralex <alex@97f52cf1-0a1b-0410-bd0e-c28be96e8082>2008-03-11 14:11:01 +0000
commitf8bfbc1f123c48c09c93a01a5e831c577cbf68fd (patch)
tree09cd36a7931c630f2f768a1f4388b11163fdba56 /upgrades/dbpatches
parent4172bff7bbc945592c4554623fd959c867eab47d (diff)
downloadzabbix-f8bfbc1f123c48c09c93a01a5e831c577cbf68fd.tar.gz
zabbix-f8bfbc1f123c48c09c93a01a5e831c577cbf68fd.tar.xz
zabbix-f8bfbc1f123c48c09c93a01a5e831c577cbf68fd.zip
- [DEV-137] updated upgrade scripts (Alexei)
git-svn-id: svn://svn.zabbix.com/trunk@5474 97f52cf1-0a1b-0410-bd0e-c28be96e8082
Diffstat (limited to 'upgrades/dbpatches')
-rw-r--r--upgrades/dbpatches/1.6/mysql/patch/drules.sql2
-rw-r--r--upgrades/dbpatches/1.6/mysql/patch/history_log.sql1
-rw-r--r--upgrades/dbpatches/1.6/mysql/patch/history_str_sync.sql1
-rw-r--r--upgrades/dbpatches/1.6/mysql/patch/history_sync.sql1
-rw-r--r--upgrades/dbpatches/1.6/mysql/patch/history_text.sql1
-rw-r--r--upgrades/dbpatches/1.6/mysql/patch/history_uint_sync.sql1
-rw-r--r--upgrades/dbpatches/1.6/mysql/patch/hosts.sql7
-rw-r--r--upgrades/dbpatches/1.6/mysql/patch/proxies.sql13
8 files changed, 11 insertions, 16 deletions
diff --git a/upgrades/dbpatches/1.6/mysql/patch/drules.sql b/upgrades/dbpatches/1.6/mysql/patch/drules.sql
index 677b45d5..4b7a2d02 100644
--- a/upgrades/dbpatches/1.6/mysql/patch/drules.sql
+++ b/upgrades/dbpatches/1.6/mysql/patch/drules.sql
@@ -1 +1 @@
-alter table drules add proxyid bigint(20) unsigned NOT NULL default '0';
+alter table drules add proxy_hostid bigint(20) unsigned NOT NULL default '0';
diff --git a/upgrades/dbpatches/1.6/mysql/patch/history_log.sql b/upgrades/dbpatches/1.6/mysql/patch/history_log.sql
new file mode 100644
index 00000000..1e3223f1
--- /dev/null
+++ b/upgrades/dbpatches/1.6/mysql/patch/history_log.sql
@@ -0,0 +1 @@
+CREATE INDEX history_log_2 on history_log (clock);
diff --git a/upgrades/dbpatches/1.6/mysql/patch/history_str_sync.sql b/upgrades/dbpatches/1.6/mysql/patch/history_str_sync.sql
new file mode 100644
index 00000000..236e827e
--- /dev/null
+++ b/upgrades/dbpatches/1.6/mysql/patch/history_str_sync.sql
@@ -0,0 +1 @@
+CREATE INDEX history_str_sync_2 on history_str_sync (clock);
diff --git a/upgrades/dbpatches/1.6/mysql/patch/history_sync.sql b/upgrades/dbpatches/1.6/mysql/patch/history_sync.sql
new file mode 100644
index 00000000..f3534c5e
--- /dev/null
+++ b/upgrades/dbpatches/1.6/mysql/patch/history_sync.sql
@@ -0,0 +1 @@
+CREATE INDEX history_sync_2 on history_sync (clock);
diff --git a/upgrades/dbpatches/1.6/mysql/patch/history_text.sql b/upgrades/dbpatches/1.6/mysql/patch/history_text.sql
new file mode 100644
index 00000000..a583aed9
--- /dev/null
+++ b/upgrades/dbpatches/1.6/mysql/patch/history_text.sql
@@ -0,0 +1 @@
+CREATE INDEX history_text_2 on history_text (clock);
diff --git a/upgrades/dbpatches/1.6/mysql/patch/history_uint_sync.sql b/upgrades/dbpatches/1.6/mysql/patch/history_uint_sync.sql
new file mode 100644
index 00000000..8e433e7c
--- /dev/null
+++ b/upgrades/dbpatches/1.6/mysql/patch/history_uint_sync.sql
@@ -0,0 +1 @@
+CREATE INDEX history_uint_sync_2 on history_uint_sync (clock);
diff --git a/upgrades/dbpatches/1.6/mysql/patch/hosts.sql b/upgrades/dbpatches/1.6/mysql/patch/hosts.sql
index 9bcd180a..4c5f5697 100644
--- a/upgrades/dbpatches/1.6/mysql/patch/hosts.sql
+++ b/upgrades/dbpatches/1.6/mysql/patch/hosts.sql
@@ -1,3 +1,6 @@
-alter table hosts add proxyid bigint unsigned DEFAULT '0' NOT NULL;
+alter table hosts add proxy_hostid bigint unsigned DEFAULT '0' NOT NULL;
+alter table hosts add lastaccess integer unsigned DEFAULT '0' NOT NULL;
+alter table hosts add inbytes bigint unsigned DEFAULT '0' NOT NULL;
+alter table hosts add outbytes bigint unsigned DEFAULT '0' NOT NULL;
alter table hosts modify ip varchar(39) DEFAULT '127.0.0.1' NOT NULL;
-CREATE INDEX hosts_3 on hosts (proxyid);
+CREATE INDEX hosts_3 on hosts (proxy_hostid);
diff --git a/upgrades/dbpatches/1.6/mysql/patch/proxies.sql b/upgrades/dbpatches/1.6/mysql/patch/proxies.sql
deleted file mode 100644
index 5acb40b9..00000000
--- a/upgrades/dbpatches/1.6/mysql/patch/proxies.sql
+++ /dev/null
@@ -1,13 +0,0 @@
-CREATE TABLE proxies (
- proxyid bigint unsigned DEFAULT '0' NOT NULL,
- name varchar(64) DEFAULT '' NOT NULL,
- lastaccess integer DEFAULT '0' NOT NULL,
- history_lastid bigint unsigned DEFAULT '0' NOT NULL,
- history_uint_lastid bigint unsigned DEFAULT '0' NOT NULL,
- history_str_lastid bigint unsigned DEFAULT '0' NOT NULL,
- history_text_lastid bigint unsigned DEFAULT '0' NOT NULL,
- history_log_lastid bigint unsigned DEFAULT '0' NOT NULL,
- dhistory_lastid bigint unsigned DEFAULT '0' NOT NULL,
- PRIMARY KEY (proxyid)
-) type=InnoDB;
-CREATE INDEX proxies_1 on proxies (name);