Database Service Installation
PostgreSYS, through PgSmart, provides a simple, easy, fast, and customizable way to install PostgreSQL and the PostGIS georeferencing extension . In addition to providing all the necessary installation packages in one place, in a single guided operation, it is possible to install PostgreSQL binaries and initialize a database instance/cluster, including creating a respective service in the operating system.
-
PgSmart Installation, observing the minimum requirements.
-
Extra package repository to resolve indirect dependencies. In accordance with the security and support policies of each organization, Tecnisys does not provide such packages. However, to assist you, we inform you that for Enterprise Linux family distributions, the Extra Packages for Enterprise Linux - EPEL repository generally provides the necessary indirect dependencies.
-
The PgSmart Agent must be installed and running on the machine where the database service will be installed.
-
PgSmart Agents Registration from PgSmart through PgSmart-Client.
pgsmart install -s cluster [Flags]
pgsmart install --service=cluster [Flags]
Flags:
-M, --pgversion=(11/12/13/14/15). Default: 15.
=> Majority version of PostgreSQL to be installed.-a, --agent= <agent>
. => Defines the alias, hostname, or IP of the server where the PgSmart Agent is installed.-h, --help
. => Shows the help.-q, --quiet
. => Non-interactive execution for service installation. Used together with --service, --pg-major-version e--agent.--geo-component.
=> Installs the Georeferencing component (PostGIS), used with the --quiet option.
This installation mode is enabled by the quiet option (--quiet, -q) and its execution uses default values for unspecified parameters. However, this option is disabled during the first installation due to the need to create the PostgreSYS package repository based on information requested interactively.
Database Management System Installation
- Command
- Video
pgsmart install -a <agent> -q --service=cluster --pg-version=(11|12|13|14|15)

Geo-component extension installation
- Command
- Video
pgsmart install -a <agent> -q --geo-component -M 15

- Instructions
- Database Management Installation - Video
- Installing the Database Extensions - Video
pgsmart install
-
Select the desired
PgSmart Agent
(or Register a new Agent). -
Select the
Database Service
. -
Select the
Major version
of environment PostgreSQL. -
Select the desired
release of environment PostgreSQL
. -
Select the
Database Service component type
to be installed.noteDepending on the choice of the Database Service component, the process will vary, as below.
5.1. If you select the Database Management System option: You will be prompted to confirm the installation of the package repository, if applicable:
5.1.1. Confirm if you want to install the PostgreSYS package repository.
5.1.2. Enter the
package repository URL
.noteThis question is not asked if the pgsys-utils repositories are already present or mapped on the machine.
5.1.3. Instance Iniciallization
-
After completing the component installation, the next step is to initialize a database instance. This step is crucial to prepare the database for use by configuring and starting the necessary services.
-
Confirm if you want to initialize a Database instance.
-
If initialization is confirmed, the system will follow the Instance Initialization process.
figure 3 -Cluster Installation - Interactive5.2. Database Extension Installation:
5.2.1. Select the
extension component
to install.5.2.2. Confirm the extension installation:
5.2.3. Confirm whether you want to install the PostgreSYS package repository.
5.2.4. Enter the package repository URL.
noteA opção de instalação do Repositório de pacotes não é realizada se os repositórios pgsys-utils já estiverem presentes ou mapeados na máquina.
Figure 4 - Extension Installation - Interactive -
Command Variations for Interactive Installation
Some parameters can be prepended in the command. However, the execution remains interactive; that is, during the installation, the parameters provided must be confirmed, along with default values for those parameters not provided.
Examples:
pgsmart install --service=cluster
pgsmart install --pg-version=15
Remember to check the installation logs for any warnings or errors during the process. Log files can provide valuable information in case of issues or for making fine adjustments to the configuration.
tail -f /var/log/pgsmart-agent/pgsmart.log
tail -f /var/log/pgsmart-client/pgsmart.log
PgSmart defines environment variables (PGDATA, PGBIN, etc) in the user's bash_profile
file , which will be reloaded in new sessions. To load these variables immediately, run the command below at the end of the installation:
source~/.bash_profile