tutorial installation agent

Installing a PostgreSQL Monitoring Agent in 2 Minutes

Targino C. Branco ·

Prerequisites

Before you begin, you need:

  • An Argus DBA account (free)
  • Root/sudo access to the server where PostgreSQL is running
  • The server needs HTTPS internet access (to communicate with Argus DBA)

Step 1: Get Your Token

After creating your account, go to Settings → Agent. You’ll see your agent token — it starts with argus_agent_. Copy it.

Step 2: Install the Agent

Linux

Run on your server terminal:

curl -s https://app.argusdba.com/install/linux.sh | bash -s -- --token YOUR_TOKEN_HERE

The script will:

  1. Download the agent binary (~10MB)
  2. Create a system user argus-agent
  3. Configure the agent as a systemd service
  4. Start monitoring automatically

Windows

Run in PowerShell as Administrator:

irm https://app.argusdba.com/install/windows.ps1 | iex

Step 3: Verify

After installation, the agent will automatically:

  • Connect to the Argus DBA server
  • Sync your PostgreSQL clusters
  • Start sending availability checks

Go back to the Argus DBA dashboard — within seconds, you’ll see your clusters with “Online” status.

How It Works Under the Hood

The agent is a statically compiled Go binary. It:

  1. Reads configuration from /etc/argus-agent/config.env
  2. Pulls the list of clusters to monitor via HTTPS API
  3. Checks TCP connectivity on each cluster (host:port)
  4. Sends results back via API
  5. Repeats at the configured interval (default: 10 seconds)

The pull model means the agent initiates all connections — no ports need to be opened on your server’s firewall.

Uninstalling

If you need to remove the agent:

curl -s https://app.argusdba.com/install/uninstall-linux.sh | bash

Use --purge to also remove configuration files.

Conclusion

In 2 minutes and 3 steps, you have PostgreSQL availability monitoring running. The agent is lightweight, secure, and requires no maintenance.


Learn why active availability monitoring is essential →

Create your free account →