Skip to content

Manage Astra Service

Learn how to control Astra services on your server: start, stop, restart, check logs, and run multiple instances for better performance and stability.

When you first launch Astra service with astra init command, default service name is astra and web interface port is 8000.

You can launch multiple Astra services on your server. Each service runs as a separate process with its own configuration and port. Common reasons to use multiple services:

  • Load distribution: Split channels across separate processes to balance resource usage
  • Improved stability: Isolate problematic channels that might affect other channels if they run in the same process

To create an additional service:

Terminal window
astra init 8002 astra2

Service name will be astra2 with the web interface port 8002.

In this example service name is default: astra2

CommandDescription
systemctl restart astra2Restart service
systemctl start astra2Start service
systemctl stop astra2Stop service
systemctl status astra2Service status
systemctl enable astra2Launch service on system startup
systemctl disable astra2Disable autorun
journalctl -fu astra2Service logs

Before removing service, stop it and turn off autorun:

Terminal window
systemctl stop astra2
systemctl disable astra2

Then, remove service from systemd:

Terminal window
astra remove astra2

This command remove service and log files, while keeping configuration and binary files.