Menu

Q4 2019 OnPremise: Prerequisite Software for Windows

Overview

Use this article to install and configure prerequisite applications before you install the Q4 2019  OnPremise deployment on a Windows machine. These prerequisite applications apply both to a single server or load balancing server.

There are 3 required prerequisites:

  • PostgreSQL - 9.5.4 to 10
    • PostgreSQL SSL Certificate is new for this release! If installing PostgresSQL with SSL connections to encrypt client/server communications for increased security, a root certificate authority (root.crt) must be created and placed in application node servers with read and write permission. This certificate will be asked when configuring the application with Command Line Wizard.
  • Elasticsearch - 6.3.5 to 6.8.1
    • Java - You are allowed to use any version of Java that is compatible with ElasticSearch 6.5-6.8.1. Use the compatibility matrix found here to determine which version of Java aligns. 

Important: We provide a range of supported versions for the prerequisite components so that OnPremise customers can easily maintain qTest OnPremise over time. This reduces the need for you to upgrade every prerequisite component each time you upgrade qTest to the most recent version.

Ports

Please note, that you must open the ports below prior to any self/assisted installation or upgrade.

PREREQUISITE APPLICATIONS

Product  Port
Postgres 5432
ElasticSearch 9200
Network Drive 2049

 

PostgreSQL 

Please note, that the example installation below, provides the recommended install version. However, you can use a prerequisite version different than these examples as long as the prerequisite version falls within the range of supported versions listed above.

Install PostgreSQL 

Follow the Postgres website for installation instructions.

IMPORTANT: Ensure that the Postgres user has the following permissions: read, write, create/delete/modify tables/schema/functions/sequences/triggers/views.

Configure PostgreSQL 

Once PostgreSQL is installed, follow steps below to enable remote access to PostgreSQL database server:

  1. Open file C:\Program Files\PostgreSQL\9.5\data\pg_hba.conf.
  2. Edit the file and append the following line to specify the IP of the server which will remotely connect to your PostgreSQL.
    Example:host all all [IP_Address] md5
    • This should be the server where qTest packages are installed.
      • If you want to allow connection from multiple client machines on a specific network, specify the network address here in the CIDR-address format.
      • If you want your PostgreSQL to accept all incoming connections regardless of the source IP address, use 0.0.0.0/0 as the IP address.
  3. Open file C:\Program Files\PostgreSQL\9.5\data\postgresql.conf. Append the following line:
    Example: listen_addresses = '*'

Create qTest Database in PostgreSQL Server

This step is to create database names that will be used when you configure qTest Manager, Sessions, Parameters, Scenario, and Pulse.

IMPORTANT: 

  • qtestctl does not support special characters "#or "?" in your PostgreSQL password

There are different ways to create a database in PostgreSQL, which we provide one of those ways below. The option below is using the 'postgres' username. In the event, you want to create a DB in Postgres with the non-default username of 'postgres' follow these instructions.

For Windows, you can use pgAdmin which is installed together with your PostgreSQL server.

  1. Open pgAdmin.
  2. Enter your username and password to connect to your PostgreSQL server
  3. On the left panel, right-click on theDatabases folderand selectNew Database...
  4. Enter your database name and select OK.
  5. Repeat this process for each qTest application you will be using that requires a database i.e. Manager, Sessions, Parameters and Pulse.
  6. Take note of the database name, as you will use it when entering values in the Command Line Wizard.

Enable SSL Mode in Postgres

  1. Open file postgresql.conf located at postgres data directory, and change the following value:
    ssl = on # (change requires restart)
    ...
    ssl_cert_file = 'path_of_cerfiticate' # (change requires restart)
    ssl_key_file = 'path_of_private_key'
    ...
  2. Open file pg_hba.conf located at postgres data directory, append this line at the end of the file.
    hostssl all all [IP_Address] md5


    Eg. hostssl all all 0.0.0.0/0 md5

Restart PostgreSQL

Run the following command to restart PostgreSQL:
net stop postgresql-x64-9.5 && net start postgresql-x64-9.5

Generate self-signed certificate: if you don't have a certificate and private key

openssl req -new -x509 -days 365 -nodes -text -out server.crt \
-keyout server.key -subj "/CN=dbhost.yourdomain.com"


chmod og-rwx server.key


openssl req -new -nodes -text -out root.csr \
-keyout root.key -subj "/CN=root.yourdomain.com"
chmod og-rwx root.key


openssl x509 -req -in root.csr -text -days 3650 \
-extfile /etc/ssl/openssl.cnf -extensions v3_ca \
-signkey root.key -out root.crt


openssl req -new -nodes -text -out server.csr \
-keyout server.key -subj "/CN=dbhost.yourdomain.com"
chmod og-rwx server.key

openssl x509 -req -in server.csr -text -days 365 \
-CA root.crt -CAkey root.key -CAcreateserial \
-out server.crt

ElasticSearch

Please note, that the example installation below, provides the recommended install version. However, you can use a prerequisite version different than these examples as long as the prerequisite version falls within the range of supported versions listed above.

Install Java JDK 1.8

Install Java JDK 1.8 prior to installing ElasticSearch.

IMPORTANT: The use of Java JDK 1.8 is an example installation with ElasticSearch. You are allowed to use any version of Java that is compatible with ElasticSearch 6.3-6.8. Use the compatibility matrix found here to determine which version of Open JDK/Oracle JDK/AMZ Corretto JDK aligns with your ES version.

Set the JAVA_HOME variable via the command line

To set the JAVA_HOME (or JRE_HOME) variable via the command line:

  1. Open the Command Prompt (make sure you Run as administrator so you're able to add a system environment variable.)
  2. Set thevalue of the environment variableto your JDK (or JRE) installation path as follows:

    setx -m JAVA_HOME "C:\Program Files\Java\jdk1.8.0_XX"

    If the path contains spaces, use the shortened path name.

  3. Restartthe Command Prompt to reload the environment variables, then use the following command to check that it's been added correctly.

    echo %JAVA_HOME%
  4. You should see the path to your JDK (or JRE) installation.

Install ElasticSearch

  1. Download the .zip file from:
    https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-6.6.0.zip
  2. Unzip the downloaded file. This will create a folder named elasticsearch-6.6.0, which will be referred to as:
     %ES_HOME%
    install_elasticsearch.png

Configure ElasticSearch

  1. Open file %ES_HOME%\config\elasticsearch.yml, and add the following line to the end of the file, to allow connections from outside of the ElasticSearch server.
    network.host: 0.0.0.0
  2. By default, ElasticSearch will use port 9200. If you would like to change the default port, open file %ES_HOME%\config\elasticsearch.yml and change the port number by adding a new configuration line, for example:
    http.port: 9201
    Note: Please make sure that you select an available port in the server and open the port to allow inbound connections.
    elasticsearch_port_info.png

Run ElasticSearch as a Windows Service

  1. Open the Command prompt and navigate to %ES_HOME%\bin
    cd D:\elasticsearch-6.6.0\bin
  2. Install Elasticsearch as a service on your Windows machine.
    elasticsearch-service.bat install
  3. Start ElasticSearch service.
    elasticsearch-service.bat start

Please refer to the official installation instructions of ElasticSearch for further information.

Powered by Zendesk