SourceForge.net Logo

openCRX Installation Guide for MySQL 4.1+

Version 1.4.0

www.opencrx.org

The contents of this file are subject to a BSD license (the "License"); you may not use this file except in compliance with the License.

You may obtain a copy of the License here



Chapter 1. About this Book

This book describes how to setup an openCRX database instance for MySQL.


Who this book is for

The intended audience are openCRX database administrators.


What do you need to understand this book

This book describes the installation of openCRX for MySQL. The book assumes that you are familiar with MySQL installation and configuration.


Chapter 2. Prerequisites

As a first step you must download the following software packages:

  • Download openCRX for MySQL from here (e.g. opencrx-1.4.0-core.MySQL-4.zip or opencrx-1.4.0-core.mysql-4.tar.gz). The distribution contains the MySQL scripts required to install the openCRX database.

  • Download MySQL Database Server from here.

  • Download the Jdbc driver MySQL Connector/J from here.

Please ensure that you install the correct JDBC driver (i.e. matching JDK, MySQL version, etc.) and one JDBC driver only! Ignoring this wisdom leads to problems as the connection to the database will fail.

As a next step you must install MySQL. The MySQL documentation explains in detail how to install the database.

This document assumes that you use the MySQL Administrator and the MySQL Query Browser for database administration. The JDBC driver is required for the application server installation.


Chapter 3. Upgrading from previous versions

If you already have MySQL for openCRX installed, upgrade the database as explained below. You can then skip the rest of this document.

The openCRX distributions provide an SQL script of the form upgrade-from-<version from>-to-<version to>.sql. E.g. If you have installed openCRX 1.3.0 and you want to upgrade to version 1.4.0 you have to run the script upgrade-from-1.3.0-to-1.4.0.sql on your database instance.


Chapter 4. Create the database

As a first step you must create the database. This can be done with MySQL Administrator. Start MySQL Administrator. Select Catalogs and then Create New Schema from the popup menu as shown in Figure 4-1.

Figure 4-1. Create a new database schema.

Enter crx-CRX as database name as shown in Figure 4-2 and click OK.

Figure 4-2. Create the schema crx-CRX.

Next you must create a database user and grant this user access to the newly created database. Select User Administration and then Add new User from the poup menu as shown in Figure 4-3.

Figure 4-3. Create a new database user.

Complete the Login Information and Additional information. We assume that you create the user system and set the password to manager.

Next you must grant the user system access to the database crx-CRX. Select the tab Schema Privileges and then select the schema crx-CRX. Move all privileges from the pane Available Privileges to the pane Assigned Privileges and click Apply changes as shown in Figure 4-4.

Figure 4-4. Create the user system and grant permissions.

You are now done creating the database.


Chapter 5. Install Database Schema

After creating the schema you are now ready to install the openCRX database schema. Start the MySQL Query Browser. Select the schema crx-CRX, then create a new script tab with File -> New Script Tab. Copy/paste the database script dbcreate-tables.sql and execute it as shown in Figure 5-1.

Figure 5-1. Install Database Schema

Similarly, load and exec the files dbcreate-indexs.sql and dbcreate-views.sql.

The scripts should run without errors. After execution the pane Schemata should list all created tables as shown in Figure 5-2.

Figure 5-2. Verify the schema installation.

Similarly, load and exec the files dbcreate-indexs.sql.

The script dbcreate-views.sql is not supported for MySQL.


Chapter 6. Next Steps

If you have completed successfully the database installation you are ready to use the openCRX database. The application server installation guides explain how to connect the application server to the openCRX database instance.


Appendix A. Appendix


Bibliography

[01] openCRX - the leading open source CRM solution, opencrx.org.

[02] openMDX - The leading open source MDA platform, openmdx.org.

http://www.crixp.com/ http://www.openmdx.org/