Code

Fix typo in server address (bug #822967).
[roundup.git] / doc / mysql.txt
1 =============
2 MySQL Backend
3 =============
5 :version: $Revision: 1.5 $
7 This notes detail the MySQL backend for the Roundup issue tracker.
10 Prerequisites
11 =============
13 To use MySQL as the backend for storing roundup data, you also need 
14 to install:
16 1. MySQL RDBMS 4.0 or higher - http://www.mysql.com. Your MySQL
17    installation MUST support InnoDB tables (or Berkeley DB (BDB) tables
18    if you have no other choice)
19 2. Python MySQL interface - http://sourceforge.net/projects/mysql-python
22 Running the MySQL tests
23 =======================
25 Roundup tests expect an empty MySQL database. Two alternate ways to provide 
26 this:
28 1. If you have root permissions on the MySQL server, you can create 
29    the necessary database entries using the follwing SQL sequence. Use
30    ``mysql`` on the command line to enter::
32        CREATE DATABASE rounduptest;
33        USE rounduptest;
34        GRANT ALL PRIVILEGES ON rounduptest.* TO rounduptest@localhost
35             IDENTIFIED BY 'rounduptest';
36        FLUSH PRIVILEGES;
38 2. If your administrator has provided you with database connection info, 
39    you can modify MYSQL_* constants in the file test/test_db.py with 
40    the correct values.
42 Note that the MySQL database should not contain any tables. Tests will not 
43 drop the database with existing data.
46 Additional configuration
47 ========================
49 To initialise and use the MySQL database backend, roundup's configuration 
50 file (config.py in the tracker's home directory) should have the following
51 entries::
53     MYSQL_DBHOST = 'localhost'
54     MYSQL_DBUSER = 'rounduptest'
55     MYSQL_DBPASSWORD = 'rounduptest'
56     MYSQL_DBNAME = 'rounduptest'
57     MYSQL_DATABASE = ( MYSQL_DBHOST, MYSQL_DBUSER, MYSQL_DBPASSWORD,
58         MYSQL_DBNAME )
60 Fill in the first four entries with values for your local MySQL installation 
61 before running "roundup-admin initialise".  Use the commands in the `Running the
62 MySQL tests` to set up a database if you have privilege, or ask your local
63 administrator if not.