Added new table to the database : log_adv_daemon
authorarjen <arjen>
Sat, 8 Feb 2003 07:36:22 +0000 (07:36 +0000)
committerarjen <arjen>
Sat, 8 Feb 2003 07:36:22 +0000 (07:36 +0000)
src/database/create.sql
src/database/destroy.sql
src/gcm_daemon/classes/gnucomo_db_version.php

index faeaecd..38fa870 100644 (file)
 -- DBA create the database and give access permissions.
 --
 --  $Log: create.sql,v $
---  Revision 1.7  2003-02-05 09:29:08  arjen
+--  Revision 1.8  2003-02-08 07:36:41  arjen
+--  Added new table to the database : log_adv_daemon
+--
+--  Revision 1.7  2003/02/05 09:29:08  arjen
 --  Bug fix: action.statuscode was in upper case.
 --
 --  Revision 1.6  2003/01/20 07:29:48  arjen
@@ -214,6 +217,13 @@ CREATE TABLE log_adv_kernel_network
        df                boolean
 ) INHERITS (log_adv);
 
+CREATE TABLE log_adv_daemon
+(
+       service TEXT,
+       event TEXT
+) INHERITS (log_adv);
+
+CREATE INDEX log_adv_daemon_service ON log_adv_daemon (service);
 
 /*
 CREATE TRUSTED PROCEDURAL LANGUAGE 'plpgsql' HANDLER "plpgsql_call_handler" LANCOMPILER '';
index e729675..550217d 100644 (file)
@@ -32,6 +32,7 @@ DROP TABLE "log";
 DROP SEQUENCE "log_advid_seq";
 
 DROP TABLE log_adv_kernel_network;
+DROP TABLE log_adv_daemon;
 DROP TABLE "log_adv";
 
 DROP TABLE "log_notification";
index 3eb32c9..08f386f 100644 (file)
       $local_sql = "UPDATE action SET statuscode = LOWER(statuscode)";
       $dbms->query($local_sql);
 
+ case 22:
+       //Create a log_adv_kernel_network table that recognizes the log-records
+       //that have come from the kernel-network interface (typically iptables).
+       $local_sql  = "CREATE TABLE log_adv_daemon (";
+       $local_sql .= "service TEXT, event TEXT";
+       $local_sql .= ") INHERITS (log_adv)";
+       $dbms->query($local_sql);
+
+ case 23:
+      $local_sql = "CREATE INDEX log_adv_daemon_service ON log_adv_daemon (service)";
+      $dbms->query($local_sql);
+
+
+
 /*    
      //These columns have to be removed when a new version of PGSQL has become mainstream that supportsa DROP COLUMN
      $local_sql = "ALTER TABLE log DROP COLUMN recognized";