Setup OAS Engine as a Linux Service or Daemon


Step 1

Note: Perform the installation on your Linux system using root access or with an account with sufficient administrative privileges.

After downloading the Linux OAS Engine from the OAS Downloads page extract the contents of to any directory of the Linux operating system.  The default path in the oas-engine.service file referenced in the Step 3 of Configure to run as a Linux Service of Daemon is /home/oasuser/OASEngine/. Change this path to match where you choose to install the OAS distribution files.

The OAS server executable file is named OASEngine. After unzipping the distribution files, this one file needs to be marked as an executable. To do this, from a Linux console navigate to the installation path where you have unzipped the files and execute the following command:

sudo chmod +x OASEngine

You will be prompted to enter the password for the root or administrator currently logged in.

You can now start the OASEngine manually from the terminal using ./OASEngine from the directory where you extracted the files.

Note: You can only run one instance of the OAS Engine per operating system.

Step 2

Once the OAS Engine is running you can open the Configure OAS from any Windows PC and enter the IP Address of the Linux system where the OAS Engine is running.


Configure to run as a Linux Service or Daemon

To configure the OAS Engine as a daemon so it can run when the system starts, and without a logged-in user implement the following steps.

Step 1

Ensure that you have systemd installed on your device by executing:

sudo apt-get install -y systemd

Step 2

Create a user under which the app will execute (choose a username and password):

sudo useradd -m username -p userpass

You can use an existing user, but keeping it separate from existing login accounts is advised, as you will be able to manage application permissions separate from any users on the system.

Step 3

Modify the oas-engine.service file located in the /daemon sub-directory (full path: /home/oasuser/OASEngine/daemon/oas-engine.service). 

Specify the ExecStart file path for OASEngine, the WorkingDirectory where the OASEngine is located, the User and Group.

This filename oas-engine.service can be anything you choose, but it will also be the name of the daemon, so choose a unique name. The configuration file should contain the following text. You can modify the “Description” and “SyslogIdentifier”, making sure the SyslogIdentifier matches the filename you choose.

Description=Open Automation Software Engine



Copy the file oas-engine.service to /etc/systemd/system. 

You can use the following command with the terminal if you need access permissions to copy to the directory.  Replace the source directory /home/oasuser/OASEngine/daemon/ with the directory where you have placed the OAS Engine.

sudo cp /home/oasuser/OASEngine/daemon/oas-engine.service /etc/systemd/system

Step 4

Navigate to /etc/systemd/system and register the daemon:

sudo systemctl daemon-reload
sudo systemctl enable oas-engine.service

The OAS Engine will now start anytime the operating system is restarted.

Step 5

Manually start the daemon using the systemctl command:

sudo systemctl start oas-engine.service

You can also start the daemon using the service command:

sudo service oas-engine start

Stopping the daemon is accomplished using the same commands, but replacing “start” with “stop”.

Step 6

You can confirm communications to your OAS Server by using the Configure OAS application on a Windows terminal.