Installation

PageSeeder installation and upgrade instructions

Configuring MySQL

Install MySQL

PageSeeder supports MySQL 5.6.4 or higher and if this is a new installation it is generally best to install the latest release of 5.7 from http://www.mysql.com .

  • On Linux use commands (CentOS 6) like:
$ rpm -Uvh https://dev.mysql.com/get/mysql57-community-release-el6-7.noarch.rpm
  • Or (CentOS 7)
$ rpm -Uvh https://dev.mysql.com/get/mysql57-community-release-el7-7.noarch.rpm
$ yum install mysql-server

Note

If upgrading from MySQL 5.6 to 5.7 you need to edit the pageseeder/webapp/WEB-INF/config/database.properties and add ?useSSL=false to the end of the DBURL e.g.

DBURL=jdbc:mysql://localhost/pageseeder?useSSL=false

Also add (or modify) the following line in your MySQL my.ini or my.cnf:

sql_mode=STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION

Finally ensure that you have the mysql-connector-java-5.1.39.jar or later in pageseeder/webapp/WEB-INF/lib and drivers folders. Restart PageSeeder after making these changes.

Install the JDBC driver

PageSeeder communicates with MySQL via the JDBC driver, therefore this must be installed on the server. Download and install on the server the MySQL Connector/J (JDBC Driver) for the existing MySQL version.

If the MySQL is the latest release, it is generally best to install the latest release of the MySQL Connector/J from http://www.mysql.com .

  • On Linux use commands like below (URL and latest version may have changed):
$ wget http://dev.mysql.com/get/Downloads/Connector-J/mysql-connector-java-5.1.39.tar.gz  
$ tar xzvf mysql-connector-java-5.1.39.tar.gz

The PageSeeder installer will ask for the location of the JDBC driver .jar file to be identified.

Use UTF-8mb4 character set

So that PageSeeder can handle special characters correctly (see Character Encoding), MySQL must be configured for UTF-8mb4. Doing so requires editing the following:

  • Windows (to see the ProgramData folder you may need to show hidden items)
\ProgramData\MySQL\MySQL Server 5.6\my.ini
  • Linux
/etc/my.cnf

Just below [mysqld] (add it if it doesn't exist) add or modify the following line:

character-set-server=utf8mb4

Change any other character-set properties to utf8mb4

Add (or modify) the following line as shown:

sql_mode=STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION

If the server has excess RAM it is usually good practice to increase the InnoDB buffer to 80% of available RAM (minus the amount taken for other processes). For example with 6GB total RAM and PageSeeder using 1GB, the InnoDB buffer could be set to 4GB by adding:

innodb_buffer_pool_size=4G

Restart MySQL on Windows via the Services Control Panel or on Linux by typing: service mysqld restart
or: service mysql restart

Warning!

If using Amazon RDS the only thing that MUST be set using DB parameter groups is character-set-server=utf8mb4

Backup and restore

Warning!

When manually creating a pageseeder database DO NOT use uft8mb4, DO use utf8 as shown below. However when backing up use --default-character-set=utf8mb4 and -r flag.

To backup the pageseeder database a command like this can be used:

$ mysqldump --single-transaction -u pageseeder -p --default-character-set=utf8mb4 -r ps.sql pageseeder

To restore the pageseeder database a command like this can be used:

$ mysql -u pageseeder -p pageseeder < ps.sql

If recreation of the database is needed before restoring, a command like this can be used:

$ mysql -u pageseeder -p
create database pageseeder character set utf8;
grant all on pageseeder.* to pageseeder@localhost identified by '<password>';
quit

Created on , last edited on