I was still trying to figure out how to gain more performance on my T2000 
director.
So I checked the performance issues stated on the documentation, both about 
postgres and mysql.
I use mysql, and the indexes are shown like this:
mysql> show index from File;
+-------+------------+----------+--------------+-------------+-----------+-------------+----------+--------+------+------------+---------+
| Table | Non_unique | Key_name | Seq_in_index | Column_name | Collation | 
Cardinality | Sub_part | Packed | Null | Index_type | Comment |
+-------+------------+----------+--------------+-------------+-----------+-------------+----------+--------+------+------------+---------+
| File  |          0 | PRIMARY  |            1 | FileId      | A         |      
854554 |     NULL | NULL   |      | BTREE      |         |
| File  |          1 | JobId    |            1 | JobId       | A         |      
     9 |     NULL | NULL   |      | BTREE      |         |
| File  |          1 | JobId_2  |            1 | JobId       | A         |      
     9 |     NULL | NULL   |      | BTREE      |         |
| File  |          1 | JobId_2  |            2 | PathId      | A         |      
 32867 |     NULL | NULL   |      | BTREE      |         |
| File  |          1 | JobId_2  |            3 | FilenameId  | A         |      
854554 |     NULL | NULL   |      | BTREE      |         |
+-------+------------+----------+--------------+-------------+-----------+-------------+----------+--------+------+------------+---------+
5 rows in set (0.15 sec)
mysql> show index from Filename;
+----------+------------+----------+--------------+-------------+-----------+-------------+----------+--------+------+------------+---------+
| Table    | Non_unique | Key_name | Seq_in_index | Column_name | Collation | 
Cardinality | Sub_part | Packed | Null | Index_type | Comment |
+----------+------------+----------+--------------+-------------+-----------+-------------+----------+--------+------+------------+---------+
| Filename |          0 | PRIMARY  |            1 | FilenameId  | A         |   
   216857 |     NULL | NULL   |      | BTREE      |         |
| Filename |          1 | Name     |            1 | Name        | A         |   
     NULL |      255 | NULL   |      | BTREE      |         |
+----------+------------+----------+--------------+-------------+-----------+-------------+----------+--------+------+------------+---------+
2 rows in set (0.00 sec)
mysql> show index from Path;
+-------+------------+----------+--------------+-------------+-----------+-------------+----------+--------+------+------------+---------+
| Table | Non_unique | Key_name | Seq_in_index | Column_name | Collation | 
Cardinality | Sub_part | Packed | Null | Index_type | Comment |
+-------+------------+----------+--------------+-------------+-----------+-------------+----------+--------+------+------------+---------+
| Path  |          0 | PRIMARY  |            1 | PathId      | A         |      
 16674 |     NULL | NULL   |      | BTREE      |         |
| Path  |          1 | Path     |            1 | Path        | A         |      
  NULL |      255 | NULL   |      | BTREE      |         |
+-------+------------+----------+--------------+-------------+-----------+-------------+----------+--------+------+------------+---------+
2 rows in set (0.00 sec)
They seem to be correct, but the documentation says how to create the indexes 
in case you don't see this output. The sql statement for the second index on 
the pdf are:
Postgres: CREATE INDEX file_fp_idx on file (filenameid, pathid);
Mysql: CREATE INDEX file_jpf_idx on File (Job, FilenameId, PathId);
...they're different on the two database, and different to what I have (I 
created the db from scratch using the shells provided with bacula). Infact, my 
second index has fields in a different order:
-
Job,
PathId,
FilenameId instead of
Job, FilenameId, PathId
I'm a bit confused...what is the correct index?
Thanx,
Gabriele.
Gabriele Bulfon - Sonicle S.r.l.
Tel +39 028246016 Int. 30 - Fax +39 028243880
Via Felice Cavallotti 16 - 20089, Rozzano - Milano - ITALY
http://www.sonicle.com
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users

Reply via email to