Skip to content

Engine Service Management

This guide covers how system administrators manage and run the Niksphere Engine as a background system service on Windows (Windows Service / SCM) and Linux (systemd).

Overview

The Niksphere Engine binary includes built-in cross-platform service management controls. This allows the Engine to be registered, started, stopped, and managed directly without requiring third-party service wrappers.

Service CLI Syntax

bash
niksphere-engine service [install|uninstall|start|stop] [flags]

Supported Flags

  • --config <path>: Absolute path to the Engine configuration file (e.g. config.yaml or config.json; see Engine Configuration Reference).
  • --service-name <name>: Custom service name (default: niksphere-engine).

Installing & Managing the Service

1. Install the Service

To register the Engine as an OS service with an explicit configuration file:

powershell
.\niksphere-engine.exe service install --config "C:\NiksphereEngine\config.yaml"
bash
sudo ./niksphere-engine service install -- "/etc/niksphere/config.yaml"

2. Start the Service

Start the registered service daemon:

Via Engine CLI

bash
niksphere-engine service start

Via OS Native Tools

powershell
Start-Service -Name "niksphere-engine"
bash
sudo systemctl start niksphere-engine

3. Stop the Service

Stop the background service gracefully:

Via Engine CLI

bash
niksphere-engine service stop

Via OS Native Tools

powershell
Stop-Service -Name "niksphere-engine"
bash
sudo systemctl stop niksphere-engine

4. Uninstall the Service

To remove the service registration from the operating system:

bash
niksphere-engine service uninstall

Custom Service Instances

For environments operating multiple isolated Engine instances on the same host machine, assign a custom service name:

powershell
# Install a second instance named 'niksphere-engine-prod-2'
.\niksphere-engine.exe service install --service-name "niksphere-engine-prod-2" --config "C:\NiksphereEngine\config-prod-2.yaml"

Service Status & Monitoring

powershell
Get-Service -Name "niksphere-engine*"
bash
sudo journalctl -u niksphere-engine -f

Release v1.0.0-build.33-channel.insider