1. Home
  2. GLU.Guide
  3. GLU DevOps
  4. GLU.Engine Deployment Guide

GLU.Engine Deployment Guide

This section describes how to setup and deploy a GLU.Engine from the point when the build button is pressed on the GLU.Console.

Prerequisites: Ensure you have the Java Runtime Environment (JRE) installed. GLU.Engines run on Java, making them compatible with any OS that supports JRE. See the GLU.Engine Server Specifications guide for specific requirements.

Installing Java JRE

GLU.Engines utilise Java 17, so ensure Java 17 is installed on the host machine running the GLU.Engine.

GLU.Engine Deployment process

Following GLU’s recommendation, the GLU.Engine runs as a user which is not root i.e. “glu” from the “/opt/glu” folder. Un-compress the tar file into the folder using the following command:

  • Navigate to the Desired Directory: Open a terminal or command prompt and navigate to the “/opt/glu” directory. If it doesn’t exist, you can create it using:
mkdir -p /opt/glu
  • Uncompress the GLUENGINE.tar.gz File: Assuming you’ve downloaded the GLUENGINE.tar.gz file from the GLU console and it’s located in your current directory, use the following command to uncompress it into the “/opt/glu” folder:
tar -xvf GLUENGINE.tar.gz -C /opt/glu

  • Access the GLUENGINE Folder: After uncompressing the file, navigate into the GLUENGINE folder using:
cd /opt/glu/GLUENGINE

All these scripts MUST be run in the folder where they were extracted:

  • Start the GLU.Engine: Use the startengine.sh shell script to start the GLU.Engine. Execute the script with the following command:

  • Monitor GLU.Engine Status: Once the services start, you can monitor the status of the GLU.Engine using the status.sh shell script. Execute the script with the following command:

  • Review Logs (Optional): If needed, review the logs generated by the GLU.Engine to ensure everything is running smoothly. Logs are typically located in a configured log folder, as set in the GLU.Console, Build Manager, GLU.Engine Settings.
  • Stop the GLU.Engine (Optional): If you need to stop the GLU.Engine for any reason, you can use the stopengine.sh shell script. Execute the script with the following command:

  • Adjust Logging Level (Optional): If you need to change the logging level of the GLU.Engine, you can use the changelogginglevel.sh shell script. Execute the script with the appropriate logging level parameter. For example:
./changelogginglevel.sh INFO

Now you’ll have access to the files and folders necessary for running the GLU.Engine. Ensure that all scripts are executed from within this directory to ensure proper functionality and avoid any potential issues.

Starting a GLU.Engine

After the initial deployment is complete, you can start the GLU.Engine using the “startengine.sh” shell script:

  • Navigate to the GLUENGINE Directory: Open a terminal or command prompt and navigate to the directory where the GLUENGINE is located:
cd /opt/glu/GLUENGINE
  • Start the GLU.Engine: Execute the “startengine.sh” shell script with the following command:
  • Monitor Services: As the services start, a message will be displayed confirming which services are starting.
  • Check Logs: The gluware.log file will appear in the log folder. This log folder location is configured in the GLU.Console, Build Manager, GLU.Engine Settings tool (see GLU.Engine Settings). You can examine the gluware.log file to monitor the execution of the GLU.Engine.
  • Confirm Successful Startup: If the GLU.Engine starts successfully, the gluware.log file will contain a row showing:
>>>>>> Glu Engine Started Successfully

Ensure that you’re executing these commands from the appropriate directory and that all necessary configurations are in place as per your setup.

Stopping a GLU.Engine

To stop the GLU.Engine processes, you can use the “stopengine.sh” shell script:

  • Navigate to the GLUENGINE Directory: Open a terminal or command prompt and navigate to the directory where the GLUENGINE is located. For example:
cd /opt/glu/GLUENGINE
  • Stop the GLU.Engine: Execute the `stopengine.sh` shell script with the following command:
  • Confirmation Message: After executing the command, a message will be displayed indicating that the GLU.Engine processes are stopping:
Stopping services…
services Stopped.

Ensure that you’re executing this command from the appropriate directory and that the `stopengine.sh` script has the necessary permissions to stop the GLU.Engine processes.

GLU.Engine Logs

The gluware.log file is specifically for the GLU.Engine and describes the actions of the start-up processes as well as the ongoing actions the GLU.Engine takes as it handles transactions.

It can be found at the path set in the GLU.Engine Settings. The gluware.log” name format and the location is configurable in the Logging tab (as below).


If you would like to put the control of starting and stopping the GLU.Engine into systemd“, you can create a Unit with the contents of the startengine.sh and stopengine.sh

systemd is a system and service manager for Linux operating systems. It provides a centralised way of managing processes, services, and other components of a Linux system. It replaces traditional init system and provides features such as parallel startup of system services, on-demand activation of daemons, resource management, and other advanced functionalities.

Creating a “systemd” unit for managing the GLU.Engine provides a more structured and efficient way to control its startup and shutdown processes.

See the example below where the contents of the java command to start the GE is used in the ExecStart and the contents of the shutdown curl is used int he ExecStop:

# GLU.Engine Unit
# Commands
# sudo cp glu.service /etc/systemd/system/glu.service
# sudo systemctl daemon-reload
# sudo service glu start
# sudo service glu status
# sudo service glu stop
# to run at boot
# sudo systemctl enable glu



ExecStart= /usr/bin/java -XX:+PrintGCDetails -Xloggc:gc.log -Xms100m -Xmx300m -XX:+UseG1GC -XX:MaxGCPauseMillis=250 -XX:+UseStringDeduplication -XX:G1HeapRegionSize=32 -XX:G1ReservePercent=15 -XX:InitiatingHeapOccupancyPercent=30 -XX:MetaspaceSize=100M -jar ./engine//syntellbp-1.0-SNAPSHOT.jar –spring.config.additional-location=./engine/config/appSetting.yml

ExecStop= /usr/bin/curl –location –request POST ‘http://localhost:9195/actuator/shutdown’


Unit Description:

  • The “[Unit]” section provides a description of the unit, specifying its name and dependencies.

Service Configuration:

    In the [Service] section:

    • Type=simple: Indicates that the service is a simple process that does not fork or create child processes.
    • Restart=always: Specifies that the service should be restarted automatically if it exits unexpectedly.
    • RestartSec=10: Sets a 10-second delay before restarting the service after it exits.
    • User=root: Specifies the user under which the service should run. You may adjust this based on your requirements.
    • WorkingDirectory: Sets the working directory for the service. Adjust this to match the directory where the GLU.Engine is located.
    • ExecStart: Defines the command to start the GLU.Engine. Adjust the memory settings, path to the JAR file, and additional parameters as needed.
    • ExecStop: Defines the command to stop the GLU.Engine. Adjust the port number to match the server port where the GLU.Engine is running.


      • The [Install] section specifies the target for installation. In this example, it’s set to “multi-user.target“, which means the unit will be started when the system reaches multi-user mode.

      Instructions for Usage:

        • Follow the provided commands to copy the unit file to the appropriate location “(/etc/systemd/system/)” and enable it.
        • Ensure to make the necessary adjustments to the unit file, such as changing the GLU.Engine name, memory settings, working directory, and port number.
        • If running multiple GLU.Engines on the same machine, ensure each service name is unique to avoid conflicts.

        Path to Commands:

          • Ensure that the paths to java and curl binaries “(/usr/bin/java and /usr/bin/curl)” are correct. You can use the whereis command to locate them if needed.

          By creating and configuring a systemd unit for the GLU.Engine, you can streamline the management of its startup and shutdown processes, enhancing efficiency and reliability. It’s also important to take note of the following when using systemd:

          • Change the file “test_client_app-1.0-SNAPSHOT” to match the GLU.Engine name you will be starting & stopping. See startengine.sh where this is defined. 
          • Change the memory settings “-Xms100m -Xmx300m” to match the settings in the “startengine.sh”
          • Change the WorkingDirectory to match the correct path/directory for the GLU.Engine.
          • Change the port “9195” in the ExecStop to match server port, see the “stopengine.sh” where this will be defined.
          • If multiple GLU.Engines are being run on the same machine, then make the service name unique to each engine, and save the unit file to a unique name i.e “glu-1.service”, adjust cp to reflect new name.
          • Ensure the “/usr/bin/java” & “/usr/bin/curl” point to where the paths to java and curl. (“whereis” command can be used to find this.)

            Was this article helpful?

            Related Articles

            Fill the form and we’ll contact you shortly

              I agree with

              We uses cookies to make your experience on this website better. Learn more
              Accept cookies