-
Notifications
You must be signed in to change notification settings - Fork 6
prometheus
Open the port 12798, as it is the default port for prometheus, as from the config.json
file.
When you start the node, it makes Prometheus metrics available at port 12798 (or whatever port you specified in config.json
). You can then setup a monitoring server or monitor your node from your local machine.
You can get the best out of prometheus if you have both Prometheus on your local machine or monitoring server and Prometheus Node Exporter on your node's server. How to do this depends on your platform and setup, but you can find documentation:
Prometheus needs to be configured to monitor your Cardano Node. A minimalistic configuration file doing this could look like this:
global:
scrape_interval: 15s
external_labels:
monitor: 'codelab-monitor'
scrape_configs:
- job_name: 'cardano' # To scrape data from the cardano node
scrape_interval: 5s
static_configs:
- targets: ['a.b.c.d:12798']
- job_name: 'node' # To scrape data from a node exporter to monitor your linux host metrics.
scrape_interval: 5s
static_configs:
- targets: ['a.b.c.d:9100']
You have to replace a.b.c.d
with the public IP-address of your Cardano Node server, which you can find on the dashboard under IPv4 Public IP.
./prometheus --config.file=prometheus.yml
./node_exporter
On your browser open a.b.c.d:9090
, pick one or more interesting metrics to graph and enjoy!
**NOTE: Security configurations you should perform on your monitoring server are out of scope for this tutorial.
The cardano-node
wiki has moved. Please go to (https://github.com/input-output-hk/cardano-node-wiki/wiki) and look for the page there.