ViewVC Help
View File | Revision Log | Show Annotations | Revision Graph | Root Listing
root/i-scream/projects/cms/source/server/db/empty.sql
(Generate patch)

Comparing projects/cms/source/server/db/empty.sql (file contents):
Revision 1.1 by pjm2, Tue Nov 28 10:10:07 2000 UTC vs.
Revision 1.6 by pjm2, Thu Mar 1 19:24:27 2001 UTC

# Line 1 | Line 1
1  
2   #
3   # This is the full definition of our (initially empty)
4 < # SQL database for i-scream logging.
4 > # SQL database for i-scream logging.  This reflects the
5 > # changes made after our original design proved to be
6 > # too large after a short amount of time.  Now, the
7 > # original XML strings are stored in the database, keyed
8 > # only by a few essential fields.
9   #
10 <
11 <
10 > # $Author$
11 > # $Id$
12   #
9 # Please note that as most records logged are stored
10 # over more than one table, it will be ESSENTIAL to
11 # place a write lock on all affected tables, removing
12 # it when done.
13 #
14
15
13   # Host: localhost Database : co600_10_db
17
18
19 # --------------------------------------------------------
14   #
21 # Table structure for table 'cpu'
15   #
16 <
24 < CREATE TABLE cpu (
25 <   id bigint(20) DEFAULT '0' NOT NULL,
26 <   cpu_no tinyint(4) DEFAULT '0' NOT NULL,
27 <   cpu_load float(10,2) DEFAULT '0.00' NOT NULL,
28 <   KEY id (id),
29 <   KEY id_2 (id),
30 <   KEY id_3 (id)
31 < );
32 <
33 <
34 <
35 < # --------------------------------------------------------
16 > # Table structure for table 'ipacket'
17   #
37 # Table structure for table 'disk'
38 #
18  
19 < CREATE TABLE disk (
20 <   id bigint(20) DEFAULT '0' NOT NULL,
42 <   p tinyint(4) DEFAULT '0' NOT NULL,
43 <   disk_free bigint(20) DEFAULT '0' NOT NULL,
44 <   disk_total bigint(20) DEFAULT '0' NOT NULL,
45 <   KEY id (id)
46 < );
19 > # Drop the table if it already exists.
20 > DROP TABLE IF EXISTS ipacket;
21  
22 <
23 < # --------------------------------------------------------
50 < #
51 < # Table structure for table 'packet'
52 < #
53 <
54 < CREATE TABLE packet (
22 > # Create the table.
23 > CREATE TABLE ipacket (
24     id bigint(20) DEFAULT '0' NOT NULL auto_increment,
25     ip varchar(15) NOT NULL,
26 <   seq_no bigint(20) DEFAULT '0' NOT NULL,
27 <   date bigint(20) DEFAULT '0' NOT NULL,
28 <   machine_name varchar(31) NOT NULL,
29 <   mac_address varchar(31),
61 <   os_name varchar(63),
62 <   os_version varchar(31),
63 <   load1 float(10,2),
64 <   load2 float(10,2),
65 <   load3 float(10,2),
66 <   mem_free bigint(20),
67 <   mem_total bigint(20),
68 <   swap_free bigint(20),
69 <   swap_total bigint(20),
70 <   users varchar(255),
71 <   full_xml text,
26 >   machine_name varchar(32) NOT NULL,
27 >   sent_date bigint(20) DEFAULT '0' NOT NULL,
28 >   receipt_date bigint(20) DEFAULT '0' NOT NULL,
29 >   xml mediumtext NOT NULL,
30     PRIMARY KEY (id),
31     KEY id (id),
32     UNIQUE id_2 (id)

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines