Configuring From the Linux Shell Command Line

Follow steps below to prepare the PostgreSQL database:

  1. Add the tigase_user:

    createuser -U admin_db_user -W -D -R -S -P tigase_user

    You will be asked for credentials for admin_db_user and password for new database user.

  2. Create the database for the Tigase server with tigase_user as owner of database:

    createdb -U admin_db_user -W -O tigase_user tigasedb
  3. Load database schema to initialize the Tigase server from the file that corresponds to the Tigase version you want to use. For the Tigase server version 5.0 and later you have to use proper schema version:

    psql -q -U tigase_user -W tigasedb -f database/postgresql-schema-5.sql

    For the Tigase server version 5.1 and later you have to use proper schema version:

    psql -q -U tigase_user -W tigasedb -f database/postgresql-schema-5-1.sql

    Above commands should be executed from the main Tigase directory. The initialization schema file should be also available locally in database/ directory of your Tigase installation.