GBS Web Apps Installation

Introduction

This manual describes the installation and update procedure of Griaule servers for Web Applications.

To perform the installation, some files need to be available on the machine where the application will be installed:

  • Application .war file, gbs-<app_name>-web-server-<version>.war;

  • Database dump script, clear-<app_name>-<DD>-<MM>-<YYYY>.sql, if installing;

  • Database upgrade script, upgrade-<app_name>-<DD>-<MM>-<YYYY>.sql, if updating;

  • Sphinx database script, clear-sphinx-<DD>-<MM>-<YYYY>.sql;

  • Apache Tomcat package, tomcats-v7.tar;

  • Setup script setup.sh;

  • Helper Python script for configuration updatescript.py;

  • Scripts for Pre-Installation: setup_webapps.sh and, optionally, setup_aliases.sh if you want to create Aliases.

circle-exclamation

To perform a new installation, follow these steps:

  1. Check whether your system meets the Prerequisites

  2. Perform the Pre-Installation using the script

  3. Install the application

  4. Configure the application

  5. Check whether the application is running using the commands presented in Handling the Applications

To update an application, follow these steps:

  1. Check whether your system meets the Prerequisites of the new version

  2. Update the application using the presented commands

  3. Check the Logout.

  4. Check whether the application is running using the commands presented in Handling the Applications

Prerequisites

circle-info

To learn more about the Griaule Biometric Suite (GBS) products, see GBS Overview.

Pre-Installation

Some steps need to be performed before the installation process.

circle-info

If Tomcat is not installed, install it with the following command:

circle-check

First, make sure the Tomcats package (file tomcats-v7.tar) provided is available on the machine where the application will be installed.

circle-info

The tomcats-v7.tar package contains one folder for each application. The folder structure is as follows:

Each folder contains the following subfolders:

triangle-exclamation

Step 1: Transfer and extract the tomcats-v7.tar package into the /var/lib/tomcats.

Step 2: Perform the application pre-installation using the setup_webapps.sh provided script.

To perform this procedure, run the pre-installation script passing the name of the application you want to install:

Step 3: Configure aliases (optional).

Optionally, if you want to create aliases to make application handling easier, run the following script:

Then, apply the .bashrc:

These scripts will:

  • Create symbolic links from tomcat for each service

  • Update/modify tomcat server scripts

  • Add aliases to make application handling easier

circle-info

After these steps, if the Cardscan Server and/or ETR are being installed, follow the steps below.

Open the database configuration file:

Under [mysqld], if CardScan is being installed, add the following line:

If ETR is being installed, add the following line:

If already configured, skip this step.

After completing the procedures above, proceed to Installation.

Installation

Before starting the installation procedure, make sure the application .war file is available on the machine where the application will be installed.

circle-check

Step 1: Move the application .war file to the application's home directory:

Step 2: Change to the application's webapps directory:

Step 3: Create a symbolic link in the webapps directory to the application .war file.

Step 4: Change directory:

Step 5: Change the ownership of the files in the tomcats directory to the user tomcat:

Then, proceed with the Logout. file.

Update

To update an application, proceed with the following steps:

circle-check

Step 1: Stop the application:

Step 2: Remove the old files:

Step 3: Place the application .war file in the application's home directory:

Step 4: Change to the application's webapps directory:

Step 5: Create a symbolic link in the webapps directory to the application .war directory:

Step 6: Run the database upgrade dumps if the release includes them:

circle-check

Step 7: Start the application:

Step 8: Change to the application's tomcats:

Step 9: Run the setup script:

Logout.

Each component has its individual configuration. These are presented in their respective manual.

circle-check

Step 1: Run the database dump:

circle-check

Step 2: Then, edit the file config.properties:

To understand the configuration procedures, consult the specific configuration manual:

circle-info

Make sure the configuration parameter Connector port=<port_number> is correctly specified in the server.xmlfile, located at /var/lib/tomcats/<app_name>/conf. For more information, consult the specific configuration manuals for each application. The connection (Connector port=<port_number>) and shutdown (Server port=... shutdown=...) ports must not be equal to each other or coincide with ports used by other applications.

circle-info

Make sure the configuration parameters <app_name>.ip, <app_name>.port and <app_name>.protocol are correctly specified in the file config.properties. The IP address must match the one configured in the server.xml. In many cases, the IP will be the same for several applications. However, each application will have a different and unique port.

Step 3: Then, log into MySQL as root:

Step 4: Run the following query:

Step 5: Exit MySQL:

Step 6: Then, start the application.

Step 7: Change to the application's tomcats:

Step 8: If it is the first time running the application, run the setup script:

circle-exclamation

Handling the Applications

This section presents some commands to monitor and handle Griaule services, as well as their respective aliases.

Aliases

Aliases are short user-defined commands that serve as substitutes for longer or more complex commands. They are created to make frequently used commands more convenient to execute. When an alias is invoked, it is replaced by the full command it represents before being executed.

If you are not using the setup_aliases.shscript, as described in Pre-Installation, you can add the aliases manually. To do this, edit the .bashrc root file:

And add the following aliases, according to the desired application:

Useful Commands

  • Start the Application

or with the alias:

  • Stop the Application

or with the alias:

  • Check the Application Status

or with the alias:

  • Check the Application Logs

or with the alias:

Last updated

Was this helpful?