2.4 Installing MySQL
Daisy requires one of the following MySQL versions:
- version 4.1.7 or a newer version from the 4.1.x series
- version 5
- what won't work: version 3 (doesn't support transactions), version 4.0 (doesn't support subselects)
MySQL can be downloaded from mysql.com. Install it now, and start it (often done automatically by the install).
Windows users can take the "Windows Essentials" package. During installation and the configuration wizard, you can leave most things to their defaults. In particular, be sure to leave the "Database Usage" to "Multifunctional Database", and leave the TCP/IP Networking enabled (on port 3306). When it asks for the default character set, select "Best Support For Multilingualism" (this will use UTF-8). When it asks for Windows options, check the option "Include Bin Directory In Windows Path".
Linux users: install the "MySQL server" and "MySQL client" packages. Installing the MySQL server RPM will automatically initialize and start the MySQL server.
2.4.1 Creating MySQL databases and users
MySQL is used by both the Daisy Repository Server and JMS (ActiveMQ). Therefore, we are now going to create two databases and two users.
Open a command prompt, and start the MySQL client as root user:
mysql -uroot -pYourRootPassword
On some systems, the root user has no password, in which case you can drop the -p parameter.
Now create the necessary databases, users and access rights by entering (or copy-paste) the commands below in the mysql client. What follows behind the IDENTIFIED BY is the password for the user, which you can change if you wish. The daisy@localhost entries are necessary because otherwise the default access rights for anonymous users @localhost will take precedence. If you'll run MySQL on the same machine as the Daisy Repository Server, you only need the @localhost entries.
CREATE DATABASE daisyrepository CHARACTER SET 'utf8'; GRANT ALL ON daisyrepository.* TO daisy@'%' IDENTIFIED BY 'daisy'; GRANT ALL ON daisyrepository.* TO daisy@localhost IDENTIFIED BY 'daisy'; CREATE DATABASE activemq CHARACTER SET 'utf8'; GRANT ALL ON activemq.* TO activemq@'%' IDENTIFIED BY 'activemq'; GRANT ALL ON activemq.* TO activemq@localhost IDENTIFIED BY 'activemq';
Previous