Verify Agent Status
After deploying the agent, use the following methods to confirm it is running correctly and communicating with the platform.
Method 1 — Check the systemd Service
systemctl status pmp4pg-agent
A healthy agent shows:
● pmp4pg-agent.service - PMP4PG Monitoring Agent
Loaded: loaded (/etc/systemd/system/pmp4pg-agent.service; enabled)
Active: active (running) since 2025-01-15 10:23:11 UTC; 5min ago
Main PID: 12345 (pmp4pg-agent)
If the service shows failed or inactive, check the logs:
journalctl -u pmp4pg-agent -n 50 --no-pager
Method 2 — Check the Agent Logs
# Live log stream
journalctl -u pmp4pg-agent -f
# Or from the log file directly
tail -f /var/log/pmp4pg-agent/agent.log
Signs of a healthy agent in the logs:
INFO Heartbeat sent successfully
INFO ASH batch sent: 50 samples
INFO pg_stat_statements delta sent: 12 statements
INFO pg_stat_database delta sent
INFO Database sizes sent: 3 databases
Signs of a problem:
ERROR Failed to connect to PostgreSQL: ...
ERROR Failed to send ASH batch: connection refused
WARN Retrying in 10s (attempt 2/3)
Method 3 — Check the Platform Dashboard
Navigate to the PMP4PG Global Dashboard in your browser:
https://pmp.data-resilience.fr
The monitored server should appear with:
- Status ACTIVE (green) — agent is running and sending heartbeats
- Last heartbeat timestamp updated within the last minute
- Agent version displayed in the server detail page
{screenshot: server-active-status-dashboard}
info
It may take up to 30 seconds after agent startup for the status to switch from INACTIVE to ACTIVE in the dashboard (heartbeat interval).
Method 4 — Server Detail Page
Click on the server in the dashboard to open the Server Detail page. The Agent Status tab shows:
| Field | Expected Value |
|---|---|
| Agent Status | ACTIVE |
| Last Heartbeat | Less than 1 minute ago |
| Agent Version | 1.0.0 |
| Agent ID | UUID matching your config.yml |
| Collectors | All enabled collectors listed as running |
{screenshot: server-detail-agent-status-tab}
Common Issues
Agent starts but status stays INACTIVE in the dashboard
- Verify the
central.api_urlinconfig.ymlis correct and reachable from the agent host - Check for firewall rules blocking outbound connections from the agent to the backend port
- Confirm
agent.idandcentral.api_keyare correctly set inconfig.yml
# Test connectivity to the backend from the agent host
curl -v http://pmp-backend.example.com:8080/pmp/actuator/health
No ASH data appearing in ASH Viewer
- Confirm the PostgreSQL monitoring user has the
pg_monitorrole - Check that
pg_stat_activityreturns rows for the monitoring user:
SELECT count(*) FROM pg_stat_activity;
- Verify the
collectors.ash.enabledis set totrueinconfig.yml
No query data in Top SQL
- Confirm
pg_stat_statementsextension is installed and enabled:
SELECT * FROM pg_stat_statements LIMIT 1;
- If the query fails, the extension is not installed. See Prerequisites →