Switch to MySQL

Step 1 : Configure a new MySQL database

Create a new database for SquashTM application, on your MySQL server.

Database Engine :

WARNING : SquashTM must be installed in InnoDB tables. Installing SquashTM with another database engine will corrupt your data. Prior to MySQL 5.5.5 the default MySQL engine was MyISAM. Please DO NOT install Squash TM on MyISAM tables and double check that your default engine is InnoDB. See your MySQL version documentation for further information on database storage engine. 

Beware of the encoding :

  • Choose collation according to the user's language
  • If your collation's name end with "_ci", the database will be case insensitive. Either "_cs" or "_bin" collations are case sensitive.
  • Prior to 1.12 version, using UTF-8 collation and above (UTF-16...) can produce error with the script "mysql-full-install.sql" (See step 3)

Create a user  having the select/insert/update/delete and "grant create temporary tables" rights on this database.

Check MySQL configuration file (usually my.cnf or my.ini). The section [mysqld] must include the following informations :

  • default-storage-engine = InnoDB
  • max_allowed_packet=X (where X is the max authorized size of attachments by Squash. By default, the application is set to 2Mo,ie X=2M)
  • Don't forget to restart MySQL (directly or using your system service) after any modification in my.cnf or my.ini

Step 2 : Populate Squash database

Use the script 'mysql-full-install.sql' found in the folder 'database-scripts/' of the Squash TM's package to populate the database you just created, 
The database administrator executing this script must have SUPER privilege.

Prior to 1.12, if you are using UTF-8 encoding, the script can produce an error line 104. Please change this line from :




If you use Mysql Workbench, you'll have to uncheck the checkbox "Safe updates" in "preferences/SQL Editor" before.

Step 3 : Configuration of Squash to use the MySQL base

From 1.13

Edit the file 'startup' in the 'bin' directory :

  • set DB_TYPE=mysql
  • set DB_URL=connection_chain based on this model : jdbc:mysql://<host>[:<port>]/<db name>
  • set DB_USERNAME= login_user_application
  • set DB_PASSWORD=password_user_application

Prior to 1.13

1/ Edit the file 'org.squashtest.csp.core.datasource.jdbc.config.properties' in the 'conf/services/' directory :
  • datasource.db.driverClassName=com.mysql.jdbc.Driver (Warning : case sensitive)
  • datasource.db.url=connection_chain based on this model : jdbc:mysql://<host>[:<port>]/<db name>
  • datasource.db.username=login_user_application
  • datasource.db.password=password_user_application 
2/ Edit the file ' org.squashtest.csp.tm.hibernate.config.properties' in the 'conf/services/' directory : 
  • hibernate.dialect=org.hibernate.dialect.MySQLDialect

3/ Clear the 'felix-cache' directory

Step 4 : Launch Squash TM

Restart Squash TM

Sign in to Squash TM with default administrator login admin/admin.