17.1. Downloading and Executing the Installer#

17.1. Downloading and Executing the Installer

17.1. Downloading and Executing the Installer #

17.1.1. Installer script #

Begin by downloading the installer script from the provided URL:

wget https://public.tantorlabs.ru/db_installer.sh

Once the download completes, grant execution permissions to the script:

chmod +x db_installer.sh

17.1.2. Installation from a local file #

This section details the process of installing Tantor SE from a local binary file. This method is useful when you have downloaded the Tantor SE binary package and wish to install it directly from your local file system.

  1. Download from personal account a .deb or .rpm file of a package compatible with your operating system and architecture.

  2. Move this file to the directory where the previously downloaded installer script db_installer.sh.

  3. Run the Tantor SE installation using the installer script db_installer.sh by specifying the path to the file .deb or .rpm of the package:

    ./db_installer.sh --from-file=<path to .deb or .rpm file of a package>
    

    For example, if you downloaded .deb package tantor-se-server-16_16.2.0_amd64.deb to the same directory as db_installer.sh then the command will look like this:

    ./db_installer.sh --from-file=./tantor-se-server-16_16.2.0_amd64.deb
    

17.1.3. Installation from Nexus #

If you have credentials to access Nexus, you can install Tantor SE directly from it.

Before running the installer, set the necessary environment variables. These variables provide the installer with credentials and the URL to access the Nexus repository:

export NEXUS_USER="<user name>"
export NEXUS_USER_PASSWORD="<password>"
export NEXUS_URL="nexus.tantorlabs.ru"

You can then run the installer with the desired options. For instance, to initialize the database after installation, specify the major version and edition, use the following command:

./db_installer.sh \
  --do-initdb \
  --major-version=16 \
  --edition=se

17.1.4. Installation Tantor Basic Edition for evaluation use #

Only the Tantor Basic Edition (BE) is available for evaluation purposes. To install the BE edition, it is necessary to set only one environment variable NEXUS_URL with the following value:

export NEXUS_URL="nexus-public.tantorlabs.ru"

And then you can run the installer script with the desired parameters:

./db_installer.sh \
  --do-initdb \
  --major-version=16 \
  --edition=be

17.1.5. Post-Installation Commands #

Once Tantor SE is installed successfully, certain post-installation commands can be used for initializing and starting the database, managing the service, uninstalling, and querying the Tantor SE version.

17.1.5.1. Initializing and starting the Database #

There are two primary methods to initialize and start the database for Tantor SE:

  • Using the installer script db_installer.sh with --do-initdb Flag:

    ./db_installer.sh --do-initdb
    

    This approach uses the installation script provided with the Tantor SE package. The --do-initdb flag automates the initialization process and starts the Tantor SE service.

  • Using the Standard initdb Command:

    su - postgres -c "/opt/tantor/db/16/bin/initdb -D /var/lib/postgresql/tantor-se-16/data"
    

    This method involves manually running the initdb command, typically located in the Tantor SE bin directory. It's crucial to specify the data directory and run the command as the Tantor SE process owner postgres.

    After successfully running initdb, the PostgreSQL server can be started using the pg_ctl command or through the system's service management tools with command:

    systemctl start tantor-se-server-16
    

In order for the Tantor SE service to start automatically when the operating system boots, run the command:

systemctl enable tantor-se-server-16

17.1.5.2. Querying Tantor SE Version #

To check the installed version of Tantor SE, you can execute a SQL command that queries the version. As the postgres user, you can retrieve the version information as follows:

su - postgres -c "psql -U postgres -d postgres -c \"select tantor_version()\""

17.1.5.3. Managing the Tantor SE Service #

To manage the Tantor SE service, such as restarting after configuration changes, use the systemctl command. For example, to restart the Tantor SE server:

systemctl restart tantor-se-server-16

17.1.5.4. Uninstalling Tantor SE #

To uninstall Tantor SE, use the package management system of your distribution. For Debian-based systems, you can remove Tantor SE using the following command:

apt-get remove tantor-se-server-16