| Crates.io | ant-metrics |
| lib.rs | ant-metrics |
| version | 0.1.30 |
| created_at | 2024-12-18 13:50:49.649543+00 |
| updated_at | 2025-07-15 16:04:00.143466+00 |
| description | Provides metrics for the Autonomi node binary |
| homepage | https://maidsafe.net |
| repository | https://github.com/maidsafe/autonomi |
| max_upload_size | |
| id | 1487642 |
| size | 59,288 |
Easily visualize metrics from Safe Network nodes using Prometheus and Grafana. This guide covers the steps to set up the dashboard and terminate it.
docker and docker-compose installed on your system and make sure they're running.--feature=open-metrics flag.Run the following command to scan the log files and fetch the metrics server URLs. These URLs will be used to create the Prometheus config file.
cargo run --release --bin metrics -- [log_dir_path]...
Note: If [log_dir_path]... is not provided, it will default to the data-dir log that nodes use by default.
The above command would write the Prometheus config file to ./metrics/prometheus/prometheus.yml
cd metrics
docker-compose up --detach
Run the binary with the --run flag to fetch the configuration file and automatically start the containers:
cargo run --release --bin metrics -- [log_dir_path]... --run
Once started, access the Grafana dashboard at: http://localhost:3001/d/node_metrics/node-metrics?orgId=1&refresh=5s
Login Credentials:
username: admin
password: pwd
To stop the containers and clear all the data:
cd metrics
docker-compose down --volumes