Skip to content

Commit

Permalink
Merge pull request #1305 from onflow/vishal/metrika_node_monitoring
Browse files Browse the repository at this point in the history
adding reference to Metrika node monitoring in the monitoring-nodes page
  • Loading branch information
bthaile authored May 4, 2023
2 parents 91ad8ba + 89593c9 commit 37e2f2f
Showing 1 changed file with 13 additions and 6 deletions.
19 changes: 13 additions & 6 deletions docs/content/node-operation/monitoring-nodes.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,19 @@ title: Monitoring Node Health
sidebar_title: Node Monitoring
---

<Callout type="info" title="Logs">
A Flow node generates logs and publishes metrics as it runs. These logs and metrics can be used to gain insights into the health of the node.

## Logs

Logs are emitted to `stdout` as JSON formed strings. Where these logs are available on your system depends on how you launch your containers. On `systemd` systems for example, the logs will be sent to the system journal daemon `journald`. Other systems may log to `/var/log`.

</Callout>
## Metrics

Flow nodes produce health metrics in the form of [Prometheus](https://prometheus.io) metrics, exposed from the node software on `/metrics`.

If you wish to make use of these metrics, you'll need to set up a Prometheus server to scrape your Nodes. Alternatively, you can deploy the Prometheus Server on top of your current Flow node to see the metrics without creating an additional server.

<Callout type="info" title="Host Metrics">
The flow-go application doesn't expose any metrics from the underlying host such as CPU, network, or disk usages. It is recommended you collect these metrics in addition to the ones provided by flow using a tool like node exporter (https://github.com/prometheus/node_exporter)
</Callout>
> The flow-go application doesn't expose any metrics from the underlying host such as CPU, network, or disk usages. It is recommended you collect these metrics in addition to the ones provided by flow using a tool like node exporter (https://github.com/prometheus/node_exporter)
1. Copy the following Prometheus configuration into your current flow node
```yaml
Expand Down Expand Up @@ -46,7 +46,7 @@ The flow-go application doesn't expose any metrics from the underlying host such

4. Open your browser and go to the URL `http://localhost:9090/graph` to load the Prometheus Dashboard

## Key Metric Overview
### Key Metric Overview

The following are some important metrics produced by the node.

Expand All @@ -57,3 +57,10 @@ The following are some important metrics produced by the node.
| consensus_compliance_sealed_height | Latest height sealed by this node; should increase at a constant rate. |
| consensus_hotstuff_cur_view | Current view of the HotStuff consensus algorith; Consensus/Collection only; should increase at a constant rate. |
| consensus_hotstuff_timeout_seconds | How long it takes to timeout failed rounds; Consensus/Collection only; values consistently larger than 5s are abnormal. |


## Monitoring a Flow node using Metrika Monitoring

Metrika has developed the Flow node monitoring service and is the recommended way of monitoring a Flow node.
It is a free tool that uses the logs and metrics published by the node and provides access to private node-specific dashboards.
Follow this [link](https://app.metrika.co/flow/node/install-agent) to setup the Metrika monitoring for your node.

0 comments on commit 37e2f2f

Please sign in to comment.