Set up the PostgreSQL Database Server on a Dual Server System

If you want to install Operations Hub on a dual server system, you must install PostgreSQL on a different machine from the one on which you want to install Operations Hub. If you want to install Operations Hub on a single server, you can skip this procedure because PostgreSQL is installed automatically and configured to work with Operations Hub when you install Operations Hub.

Before you begin

You can install PostgreSQL on any machine that supports running PostgreSQL and meets the following criteria:
  • Has a fixed IP address.
  • Is accessible by the machine on which you want to install Operations Hub.
  • The standard PostgreSQL port, 5432, allows remote connection with the machine on which Operations Hub is installed.
  • PostgreSQL is configured to allow a Operations Hub user to access the database remotely using the machine on which Operations Hub is installed.

About this task

This topic describes how to set up PostgreSQL installed on Ubuntu Server 16.04 LTS to work with Operations Hub.

Procedure

  1. Install Ubuntu Server 16.04 LTS on the machine on which you want to install PostgreSQL.
    Tip: You can download the installer for Ubuntu Server 16.04 LTS by selecting the 64-bit PC (AMD64) server install image link from the following location: http://releases.ubuntu.com/16.04/
    Note: Perform a standard installation of the Ubuntu server.
  2. Install PostgreSQL.
    Note: The recommended version is v10.5.
  3. Copy the Operations Hub installation file to a folder on the machine (for example, /home/user/studio).
    Tip: The database set up files are available in the Operations Hub installation folder.
  4. Change to the folder where you copied the installation file and decompress it by running the following commands:
    cd /home/user/studio
    tar -zxvf OpHub_<version>.tar.gz                                                                                
  5. Provide access to the folder that contains the database set up files by running the following commands:
    cd /home/user/studio/assets
    chmod -R 777 db
  6. Create a shell for the default PostgreSQL user by running the following command: sudo -i -u postgres
  7. Change to the folder in which the file is stored by running the following command: cd /home/user/studio/assets/db
  8. Run the script by running the following command: ./create_db.sh
    A message appears, asking you to enter the database name.
  9. Accept the default name or enter a different name, and press Enter.
    The database schemas and tables in PostgreSQL are now set up to work with Operations Hub.

What to do next

Install Operations Hub.