[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bacula-devel] small mysql patch


Hi,

I believe that the results of this discussion concerns

"[Bacula-users] Bacula 2.2.8, dbcheck never completes"
http://sourceforge.net/mailarchive/forum.php?thread_name=48A984BF.4050206%40umdnj.edu&forum_name=bacula-users

requires a small patch, see attached file.

Since all fields (which fall in the indices) type INTEGER  the size of
the indices will be low and increase speed dbcheck will be very
substantial.

As you think?

ps. I think the same indices are needed for DB Postgresql.

-- 
with best regards
Index: bacula/src/cats/make_mysql_tables.in
===================================================================
--- bacula/src/cats/make_mysql_tables.in	(revision 7531)
+++ bacula/src/cats/make_mysql_tables.in	(working copy)
@@ -44,13 +44,14 @@
 
 #
 # Possibly add one or more of the following indexes
-#  to the above File table if your Verifies are
+#  to the above File table if your Verifies or/and dbcheck are
 #  too slow.
 #
-#  INDEX (PathId),
-#  INDEX (FilenameId),
-#  INDEX (FilenameId, PathId)
-#  INDEX (JobId),
+#  CREATE INDEX idxP   ON File (PathId);
+#  CREATE INDEX idxFI  ON File (FilenameId);
+#  CREATE INDEX idxJPF ON File (JobId, PathId, FilenameId);
+#  CREATE INDEX idxFJ  ON File (FileId, JobId);
+#  CREATE INDEX idxPJ  ON File (PathId, JobId);
 #
 
 CREATE TABLE MediaType (
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Bacula-devel mailing list
Bacula-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.sourceforge.net/lists/listinfo/bacula-devel


This mailing list archive is a service of Copilotco.