Read-only monitoring
The agent collects operating system information without restarting services, killing processes or changing server settings.
Install the lightweight agent on your Linux server to securely send CPU, memory, disk, network, process, service and port metrics to the Server Guardian Pro app.
The agent collects operating system information without restarting services, killing processes or changing server settings.
The Pro agent sends data to the backend through HTTPS. You do not need to expose port 9091 or create a new inbound firewall rule.
A unique token identifies the installation. Keep it private and use it only to link this server inside the Server Guardian Pro app.
Run the complete block below as a user with sudo access. It detects the CPU architecture, downloads the correct binary, creates the configuration and installs the systemd service.
serverguardianpro.projy.ai.
set -e
MACHINE="$(uname -m)"
case "$MACHINE" in
x86_64|amd64)
BUILD="amd64"
;;
aarch64|arm64)
BUILD="arm64"
;;
i386|i486|i586|i686)
BUILD="386"
;;
*)
echo "Unsupported architecture: $MACHINE"
exit 1
;;
esac
DOWNLOAD_URL="https://projy.nyc3.cdn.digitaloceanspaces.com/server-guardian-pro/server-guardian-pro-agent-linux-${BUILD}"
SERVER_HOSTNAME="$(hostname)"
sudo install -d -m 0755 /usr/local/bin
sudo install -d -m 0755 /etc/server-guardian-pro
curl -fL "$DOWNLOAD_URL" -o /tmp/server-guardian-pro-agent
sudo install -m 0755 /tmp/server-guardian-pro-agent /usr/local/bin/server-guardian-pro-agent
rm -f /tmp/server-guardian-pro-agent
if [ ! -f /etc/server-guardian-pro/config.json ]; then
sudo tee /etc/server-guardian-pro/config.json >/dev/null <<JSON
{
"base_url": "https://serverguardianpro.projy.ai",
"server_uuid": "${SERVER_HOSTNAME}",
"agent_token": "",
"agent_uuid": "",
"agent_version": "1.0.0",
"fast_poll_seconds": 5,
"metrics_poll_seconds": 60,
"inventory_poll_minutes": 30,
"send_processes": true,
"send_services": true,
"send_ports": true,
"max_processes": 50,
"max_services": 100,
"max_ports": 100,
"ports_to_check": [22, 80, 443, 3306, 5432, 6379, 9091],
"log_file": "/var/log/server-guardian-pro.log"
}
JSON
sudo chmod 0600 /etc/server-guardian-pro/config.json
fi
sudo tee /etc/systemd/system/server-guardian-pro-agent.service >/dev/null <<'SERVICE'
[Unit]
Description=Server Guardian Pro Agent
After=network-online.target
Wants=network-online.target
[Service]
Type=simple
User=root
WorkingDirectory=/etc/server-guardian-pro
ExecStart=/usr/local/bin/server-guardian-pro-agent
Restart=always
RestartSec=5
NoNewPrivileges=true
PrivateTmp=true
[Install]
WantedBy=multi-user.target
SERVICE
sudo systemctl daemon-reload
sudo systemctl enable --now server-guardian-pro-agent
sudo systemctl status server-guardian-pro-agent --no-pager
active (running). On the first successful check-in, the agent generates or stores its private identity values in the configuration file.
Use uname -m to identify your server architecture, then download the matching executable.
uname -m
| Build | Recommended for | Download | Manual command |
|---|---|---|---|
| linux-amd64 | Most VPS, dedicated servers, cloud instances and x86_64 Linux machines. |
server-guardian-pro-agent-linux-amd64 |
|
| linux-arm64 | ARM 64-bit servers, AWS Graviton and modern Raspberry Pi systems. |
server-guardian-pro-agent-linux-arm64 |
|
| linux-386 | Legacy 32-bit Intel and compatible Linux systems. |
server-guardian-pro-agent-linux-386 |
chmod +x server-guardian-pro-agent
sudo install -m 0755 server-guardian-pro-agent /usr/local/bin/server-guardian-pro-agent
The agent uses /etc/server-guardian-pro/config.json. The backend can return plan limits and collection intervals, while the local file keeps the server identity and collection preferences.
agent_token in a URL, public screenshot, support ticket, shell history or source repository.
Open the configuration file using the server editor.
sudo vi /etc/server-guardian-pro/config.json
Only root should be able to read or change the agent identity.
sudo chown root:root /etc/server-guardian-pro/config.json
sudo chmod 0600 /etc/server-guardian-pro/config.json
{
"base_url": "https://serverguardianpro.projy.ai",
"server_uuid": "server01",
"agent_token": "",
"agent_uuid": "",
"agent_version": "1.0.0",
"fast_poll_seconds": 5,
"metrics_poll_seconds": 60,
"inventory_poll_minutes": 30,
"send_processes": true,
"send_services": true,
"send_ports": true,
"max_processes": 50,
"max_services": 100,
"max_ports": 100,
"ports_to_check": [22, 80, 443, 3306, 5432, 6379, 9091],
"log_file": "/var/log/server-guardian-pro.log"
}
After the service starts and completes its first check-in, use the generated agent token to claim the server in Server Guardian Pro.
sudo grep '"agent_token"' /etc/server-guardian-pro/config.json
Use these commands when the server does not appear online in the app or metrics stop updating.
sudo systemctl status server-guardian-pro-agent --no-pager
sudo journalctl -u server-guardian-pro-agent -f
sudo tail -n 100 /var/log/server-guardian-pro.log
An HTTP 401 response is expected without a token and confirms that DNS, TLS and the backend route are reachable.
curl -sS -o /dev/null -w 'HTTP %{http_code}\n' \
https://serverguardianpro.projy.ai/api/serverguardian/agent/config
Restart the service after editing the JSON file.
sudo systemctl restart server-guardian-pro-agent
sudo systemctl status server-guardian-pro-agent --no-pager
Download the newest binary for the current architecture, replace the executable and restart the service. The existing configuration and token are preserved.
set -e
case "$(uname -m)" in
x86_64|amd64) BUILD="amd64" ;;
aarch64|arm64) BUILD="arm64" ;;
i386|i486|i586|i686) BUILD="386" ;;
*) echo "Unsupported architecture: $(uname -m)"; exit 1 ;;
esac
DOWNLOAD_URL="https://projy.nyc3.cdn.digitaloceanspaces.com/server-guardian-pro/server-guardian-pro-agent-linux-${BUILD}"
curl -fL "$DOWNLOAD_URL" -o /tmp/server-guardian-pro-agent
sudo systemctl stop server-guardian-pro-agent
sudo install -m 0755 /tmp/server-guardian-pro-agent /usr/local/bin/server-guardian-pro-agent
rm -f /tmp/server-guardian-pro-agent
sudo systemctl start server-guardian-pro-agent
sudo systemctl status server-guardian-pro-agent --no-pager
sudo systemctl disable --now server-guardian-pro-agent
sudo systemctl disable --now server-guardian-pro-agent
sudo rm -f /etc/systemd/system/server-guardian-pro-agent.service
sudo rm -f /usr/local/bin/server-guardian-pro-agent
sudo rm -rf /etc/server-guardian-pro
sudo systemctl daemon-reload