Skip to content

PostgreSQL Configuration

Overview

This section explains how to set up postgres to work properly with Etendo Classic, once you have installed postgres, you need to make sure that the configuration is set up properly.

System User configuration

When you install postgres, it creates a system user called postgres, if you not set up a password for this user, you can do it by running the following command

Terminal
sudo -u postgres psql
You will inmediatly enter the postgresql shell, then you can set up the password by running the following example:

Postgresql Shell
ALTER USER postgres PASSWORD 'syspass';

Info

Etendo Classic has syspass preconfigured as the default password for the postgres user. In case of changing the system password, this configuration variable should be changed by following the Etendo Classic installation guide.

Etendo Classic User configuration

Warning

In case of installing Etendo from scratch by executing the command ./gradlew install, the installation process creates the default user and password tad automatically, and they are already includes preconfigured. In case you do not need to change the tad user, you can skip this section.

If you need to create a Postgres user and password for the Etendo application, you can do it by running the following command

Terminal
PGPASSWORD=system_password psql -U postgres -d postgres -h localhost

You will inmediatly enter the postgresql shell, then you can create the user by running the following example:

Postgresql Shell
CREATE ROLE tad LOGIN PASSWORD 'tad'  CREATEDB CREATEROLE VALID UNTIL 'infinity';

Note

The user and password created can be configured in the gradle.properties file, as can be seen in the Etendo Classic installation guide.

Required Configuration

Make sure you have the following PostgreSQL configuration in your postgresql.conf, this file is located wherever you have postgresql installed

postgresql.conf
lc_numeric = 'en_US.UTF-8'
max_locks_per_transaction = 128

Required PostgreSQL extensions

Etendo Classic currently requires two PostgreSQL extensions to be available:

uuid-ossp to generate UUID's pg_trgm to have index support for fast contains search

Since version 10 those are part of the normal PostgreSQL server installation.

Note

After modifying the file restart postgresql service