warning
This article requires a revision.
Setting up local Metrics infrastructure
Metrics Configuration
Nethermind metrics can be consumed by Prometheus/Grafana if configured in Metrics configuration category.
Metrics infrastructure
Enabling Metrics in Nethermind
Metrics can be enabled by simply passing --Metrics.Enabled true
argument to the Docker containers,Nethermind.Runner
or Nethermind.Launcher
e.g. ./Nethermind.Runner --Metrics.Enabled true
.
Metrics.PushGatewayUrl
will need to be amended if pushgateway endpoint is not default.
Running sample configuration
- clone metrics-infrastructure repository
git clone https://github.com/NethermindEth/metrics-infrastructure.git
- go to
metrics-infrastructure
directory
cd metrics-explanation-infrastructure
- run docker stack
docker-compose up -d
- Prometheus instance should be now running on
http://localhost:9090/
- Pushgateway on
http://localhost:9091/
- Grafana on
http://localhost:3000/
``
- run the
Nethermind
node withMetrics
enabled and you should see metrics inflowing on Pushgateway url
info
You can add nethermind service to the docker-compose.yml
file so that it runs with the whole stack
nethermind:
image: nethermind/nethermind
container_name: nethermind
restart: unless-stopped
command: '--config goerli --Metrics.Enabled true'
network_mode: host
volumes:
- ./nethermind_db/:/nethermind/nethermind_db/
- ./keystore/:/nethermind/keystore/
- ./logs/:/nethermind/logs/
- Runner
- Launcher
- Docker
./Nethermind.Runner --Metrics.Enabled true
./Nethermind.Launcher --Metrics.Enabled true
docker run -it --network host nethermind/nethermind:alpine --Metrics.Enabled
- open Grafana url and login with default login (admin) and password (admin), skip password change if you want
- go to dashboards management
http://localhost:3000/dashboards
and clickNethermind
- you can now explore metrics and monitor your Nethermind node