Index: trunk/cgi-bin/ipdb-2.7-3.0.sql
===================================================================
--- trunk/cgi-bin/ipdb-2.7-3.0.sql	(revision 776)
+++ trunk/cgi-bin/ipdb-2.7-3.0.sql	(revision 779)
@@ -13,4 +13,18 @@
 );
 
+-- Store backup fields in a separate table
+CREATE TABLE backuplist (
+    backup_id serial NOT NULL,
+    bkbrand text,
+    bkmodel text,
+    bktype text,
+    bkport integer,
+    bksrc text,
+    bkuser text,
+    bkvpass text,
+    bkepass text,
+    ip inet
+);
+
 -- Master and routed blocks now live in the allocations table.
 
@@ -20,6 +34,8 @@
 ALTER TABLE allocations ADD COLUMN parent_id integer NOT NULL DEFAULT 0;
 ALTER TABLE allocations ADD COLUMN master_id integer NOT NULL DEFAULT 0;
+ALTER TABLE allocations ADD COLUMN backup_id integer NOT NULL DEFAULT 0;
 ALTER TABLE allocations DROP CONSTRAINT allocations_pkey;
 ALTER TABLE allocations ADD COLUMN id serial PRIMARY KEY;
+-- not certain this is right
 CREATE UNIQUE INDEX allocations_skey ON allocations (cidr,vrf,type);
 
@@ -37,4 +53,5 @@
 ALTER TABLE poolips ADD COLUMN parent_id integer NOT NULL DEFAULT 0;
 ALTER TABLE poolips ADD COLUMN master_id integer NOT NULL DEFAULT 0;
+ALTER TABLE poolips ADD COLUMN backup_id integer NOT NULL DEFAULT 0;
 ALTER TABLE poolips DROP CONSTRAINT poolips_pkey;
 ALTER TABLE poolips ADD COLUMN id serial;
