Monitor validators
If you use the Clique or IBFT 2.0 proof of authority (PoA) consensus protocols, determine whether all validators are proposing blocks to identify possible network problems.
Enable monitoring of validators on the command line by specifying the POA
metrics category and optionally specifying the number of recently added blocks to check.
`besu --metrics-enabled --metrics-categories=POA --plugin-metrics-recent-block-count=50`
The command line statement:
- Enables metrics using the
--metrics-enabled
option. - Specifies the
POA
metrics category using the--metrics-categories
option. - Specifies the number of recently added blocks to check using the
--plugin-metrics-recent-block-count
option.
Viewing metrics
Configure and run Prometheus as described for Hyperledger Besu.
Open a web browser to
http://localhost:9090
to view the Prometheus graphical interface.Select Graph from the menu bar and select the Console tab.
From the Insert metric at cursor drop-down, select one of the following metrics, and select Execute. The values are displayed.
Name | Metric type | Definition | JSON-RPC equivalent |
---|---|---|---|
plus_poa_ibft_recent_signed_count | Gauge | Number of times this node was a block signer in the last n blocks, where n is the value specified for --plugin-metrics-recent-block-count | None |
plus_poa_ibft_rounds_for_latest_block | Gauge | Number of rounds required to import the latest block | None |
plus_poa_ibft_unique_recent_signers | Gauge | Number of unique signers in the last n blocks, where n is the value specified for --plugin-metrics-recent-block-count | None |
plus_poa_recent_proposer_count | Gauge | Number of unique validators proposing blocks in the last n blocks, where n is the value specified for --plugin-metrics-recent-block-proposer-count | clique_getSignerMetrics , ibft_getSignerMetrics |
plus_poa_recently_proposed_block_count | Gauge | Number of times this validator proposed an accepted block in the last n blocks, where n is the value specified for --plugin-metrics-recent-block-count | clique_getSignerMetrics , ibft_getSignerMetrics |
plus_poa_validator_count_current | Gauge | Number of validators currently defined | clique_getSignerMetrics , ibft_getSignerMetrics |
(Optional) Visualize the collected data using Grafana.
- Start Grafana.
- Open a web browser to http://localhost:3000 to view the Grafana graphical interface, and log in. For first-time users, the default name is admin, and the default password is admin.
- Import
PegaSys+-dashboard-grafana.json
located in<your-installation-directory/dashboard>
to create the dashboard.