Install the Host Agent

The NoDisrupt host agent is a small binary that runs on your server, collects system-level metrics such as CPU, memory, disk and network usage, and posts them back to NoDisrupt on a regular interval. Once it is running, those metrics appear on the Server Metrics monitor you created for that host, alongside your uptime and latency data.

Requirements

  • A Linux server, amd64 or arm64.
  • systemd (the installer manages the agent as a systemd service).
  • Root or sudo access.
  • Outbound HTTPS access to api.production.nodisrupt.com (where metrics are sent) and downloads.nodisrupt.com (where the agent binary is downloaded from).

Quick install

The app generates a ready-to-run install command with your credentials already filled in. Open Monitor -> Server Metrics -> Install the agent to get the exact command for your monitor. It looks like this:

NODISRUPT_AUTH_KEY='<your-auth-key>' NODISRUPT_METRIC_ID='<your-monitor-id>' \
  sudo -E bash -c "$(curl -fsSL https://downloads.nodisrupt.com/agent/install.sh)"

Run it on the server you want to monitor. It downloads the agent, writes its configuration and starts the service, all in one step.

Warning

The generated command contains a live credential (NODISRUPT_AUTH_KEY) that lets the agent report metrics for your monitor. Treat it like a password: do not paste it into shared scripts, commit it to a repository, or post it anywhere public.

What the installer does

  • Downloads the agent binary built for your server's architecture (amd64 or arm64).
  • Verifies the download against a published SHA-256 checksum before installing anything.
  • Installs the binary to /opt/nodisrupt-agent/bin.
  • Writes /etc/nodisrupt/agent.yaml with your configuration, owned by root and readable only by root (mode 0600).
  • Installs and starts the hardened nodisrupt-agent.service systemd unit.
  • Waits for the service to reach a running state and confirms it before exiting, so you know immediately if something went wrong.

Configuration reference

The agent reads its configuration from /etc/nodisrupt/agent.yaml:

  • api_base - string. The NoDisrupt API endpoint the agent reports to.
  • metric_id - string. The id of the monitor this agent's metrics are attached to.
  • auth_key - string. The orgId:token credential the agent authenticates with.
  • interval - duration. How often the agent collects and sends metrics. Defaults to 60s.
  • tags - list of strings, optional. Free-form labels attached to every metrics payload, useful for filtering hosts by environment or role.
  • debug - boolean. Enables verbose logging for troubleshooting.
Note

If you edit agent.yaml by hand, the running agent will not pick up the change until you restart it: sudo systemctl restart nodisrupt-agent.

Manual installation

If you cannot use the one-line installer, for example on a host without outbound access to run the script directly, you can install the agent by hand.

Download the tarball and checksums for your architecture. The commands below use the amd64 build; on an arm64 server, replace amd64 with arm64 in both the download and extract commands.

curl -fsSLO https://downloads.nodisrupt.com/agent/latest/nodisrupt-agent_linux_amd64.tar.gz
curl -fsSLO https://downloads.nodisrupt.com/agent/latest/checksums.txt

Verify the checksum before extracting anything:

sha256sum -c checksums.txt --ignore-missing

Extract the binary into place:

sudo mkdir -p /opt/nodisrupt-agent/bin
sudo tar -xzf nodisrupt-agent_linux_amd64.tar.gz -C /opt/nodisrupt-agent/bin

Write the configuration file yourself, with your own credentials:

sudo mkdir -p /etc/nodisrupt
sudo tee /etc/nodisrupt/agent.yaml > /dev/null <<'EOF'
api_base: "https://api.production.nodisrupt.com"
metric_id: "<your-monitor-id>"
auth_key: "<your-auth-key>"
interval: "60s"
debug: false
EOF
sudo chmod 0600 /etc/nodisrupt/agent.yaml

Create the systemd unit at /etc/systemd/system/nodisrupt-agent.service with exactly this content:

[Unit]
Description=NoDisrupt Host Agent
Documentation=https://nodisrupt.com/docs/host-agent/install
After=network-online.target
Wants=network-online.target

[Service]
Type=simple
ExecStart=/opt/nodisrupt-agent/bin/nodisrupt-agent -config /etc/nodisrupt/agent.yaml
Restart=on-failure
RestartSec=5s
User=root

# Hardening
NoNewPrivileges=true
PrivateTmp=true
ProtectSystem=strict
ProtectHome=true
ReadOnlyPaths=/etc/nodisrupt

[Install]
WantedBy=multi-user.target

Then load and start it:

sudo systemctl daemon-reload && sudo systemctl enable --now nodisrupt-agent

Managing the service

The agent runs as a normal systemd service, so the usual commands apply:

sudo systemctl status nodisrupt-agent
sudo systemctl restart nodisrupt-agent
sudo systemctl stop nodisrupt-agent

To follow its logs live:

sudo journalctl -u nodisrupt-agent -f

Upgrading

Re-run the same installer command with no credentials set. Without NODISRUPT_AUTH_KEY and NODISRUPT_METRIC_ID, the installer detects your existing /etc/nodisrupt/agent.yaml, leaves it untouched, and only updates the binary and service.

To pin the agent to a specific release instead of always installing the latest version, set NODISRUPT_AGENT_VERSION:

NODISRUPT_AGENT_VERSION=v1.0.0 sudo -E bash -c "$(curl -fsSL https://downloads.nodisrupt.com/agent/install.sh)"

Troubleshooting

401 Unauthorized in logs

The agent's auth_key is wrong, or has been revoked. Generate a fresh install command from Monitor -> Server Metrics -> Install the agent and re-run the installer with the new credentials.

The service runs but no metrics show up

Check that metric_id in /etc/nodisrupt/agent.yaml matches the monitor you expect the agent to report to, and that api_base is set to https://api.production.nodisrupt.com. Then check the journal for a post failed message, which usually points to a network or DNS problem reaching the API:

sudo journalctl -u nodisrupt-agent -n 100

"systemd is required"

The installer refuses to run on hosts without systemd, since it cannot manage the service reliably. Non-systemd hosts need a manual process supervisor of your own choosing; this is currently out of scope for the installer and this guide.

Uninstall

curl -fsSL https://downloads.nodisrupt.com/agent/uninstall.sh | sudo bash

To also remove the configuration file at /etc/nodisrupt/agent.yaml, add --purge:

curl -fsSL https://downloads.nodisrupt.com/agent/uninstall.sh | sudo bash -s -- --purge
Note

Want to know exactly what the agent reports? See Metrics Collected.