Managing services for on-prem, self-hosted customers after installation.
Overview
After installation, services are managed with the unified service manager script $agilesec_install_dir/scripts/manage.sh.
manage.sh provides a centralized way to manage all platform services:
cd $agilesec_install_dir
./scripts/manage.sh [action] [options] [services...]
If no specific services are specified, the action will be applied to all installed services.
Optional: systemd
systemd is an optional Linux service manager not enabled by default. systemd requires more resources and introduces more system complexity than default binary service management. Advanced users may utilize systemd for more dynamic service handling if needed.
Note: systemd does require sudo privileges or root login to start services.
Enable systemd
The startup script startup.sh can be used to enable systemd after AgileSec installation:
sudo $agilesec_install_dir/scripts/startup.sh systemd enable
Verify systemd installation
Verify if all new kf_agilesec* units are installed and enabled:
systemctl list-unit-files | grep kf_agilesec
start systemd services
After enabling systemd, users can either continue to use manage.sh for managing services or use systemd commands.
Start all services and check status with manage.sh:
sudo $agilesec_install_dir/scripts/manage.sh start
sudo $agilesec_install_dir/scripts/manage.sh status
Disable systemd
systemd enablement is persistent. systemd can be disabled by running the following:
sudo $agilesec_install_dir/scripts/startup.sh systemd disable
manage.sh Actions
|
Action |
Description |
|---|---|
|
|
Start services |
|
|
Stop services |
|
|
Stop and then start services |
|
|
Reload service configuration where supported |
|
|
Check status of services |
|
|
List available services |
|
|
Display help message |
manage.sh Options
|
Option |
Description |
|---|---|
|
|
Enable debug mode (show service output in console). |
|
|
Enable silent mode. No output is displayed. |
|
|
Exclude service(s) listed after this flag from the action. (Comma-separated list is expected.) |
|
|
Disable health check cron (comment out crontab entry) to prevent restarting services during the upgrade. |
|
|
Re-enable health check cron (uncomment crontab entry). |
|
|
Display helpful script information. |
AgileSec Platform Services
|
Service |
Description |
|---|---|
|
|
HAProxy Load Balancer |
|
|
OpenSearch Search Engine |
|
|
OpenSearch Dashboards |
|
|
MongoDB Server |
|
|
Kafka Server |
|
|
Indexing Microservice |
|
|
Web UI Microservice |
|
|
Web API Microservice |
|
|
Security Manager Microservice |
|
|
Analytics Manager Microservice |
|
|
Ingestion Microservice |
|
|
Scheduler Microservice |
|
|
Fluentd Data Collector. Deprecated unless backwards compatibility with v2 sensors is enabled. |
manage.sh Usage Examples
-
To start all services:
./manage.sh start
-
To start only OpenSearch with debug output:
./manage.sh start -d opensearch
-
To start multiple specific services:
./manage.sh start opensearch opensearch-dashboards
The script automatically resolves dependencies, starting OpenSearch first (as it's a dependency for other services) before starting any dependent services.
-
To stop all services:
# Stop all installed services
./manage.sh stop
-
To stop only specific services:
./manage.sh stop haproxy indexing
The script stops services in reverse dependency order to ensure a clean shutdown.
-
To Restart all installed services:
# Restart all installed services
./manage.sh restart
-
To restart only OpenSearch:
./manage.sh restart opensearch
-
To reload configuration:
./manage.sh reload haproxy
-
To list status of all services:
./manage.sh status
-
To check status of specific services:
./manage.sh status opensearch indexing
-
To list all available services:
./manage.sh list
Note: If HAProxy is configured to use a privileged port (< 1000), you will need root privileges to start or stop it. The script will display the appropriate command to run with sudo.