Wiki source code of Database Administration

Version 1.3 by Vincent Massol on 2007/08/27

Show last authors
1 1 Database Administration
2
3 XWiki uses by default a database to store its data. You will find on this page tips and tricks to administer and tune your database setup. For Installation please check the [Installation>Installation#HInstallandconfigureaRelationalDatabase] page which contains information on how to setup XWiki for multiple databases.
4
5 1.1 Indexes
6
7 To improve your XWiki instance when running with many documents you should run the following script to create indexes for your database. This has been tested for MySQL 4.x and 5.0.
8
9 {code}
10 create index xwd_name on xwikidoc (xwd_name);
11 create index xwd_fullname on xwikidoc (xwd_fullname);
12 create index xwd_web on xwikidoc (xwd_web);
13 create index xwd_name on xwikiobjects (xwo_name);
14 create index xwl_value on xwikilongs (xwl_value);
15 create index xwi_value on xwikiintegers (xwi_value);
16 create index xws_value on xwikistrings (xws_value);
17 create index xwl_value on xwikilargestrings (xwl_value(50));
18 create index xwo_classname on xwikiobjects (xwo_classname);
19 create index xwd_creation_date on xwikidoc (xwd_creation_date);
20 create index xwd_date on xwikidoc (xwd_date);
21 create index xwd_content_update_date on xwikidoc (xwd_content_update_date);
22 create index xwd_content_author on xwikidoc (xwd_content_author);
23 create index xwd_author on xwikidoc (xwd_author);
24 create index xwd_creator on xwikidoc (xwd_creator);
25 create index xwd_language on xwikidoc (xwd_language);
26 create index xwd_default_language on xwikidoc (xwd_default_language);
27 create index xwd_title on xwikidoc (xwd_title);
28 create index xwd_parent on xwikidoc (xwd_parent(50));
29 {code}
30
31 1.1 Sanity Checks
32
33 To verify the consistency of your XWiki database you can run the following {attach:sanity check script|sanitycheck.sql}. It has been tested for MySQL 5.0.

Get Connected