Installation Node Monitoring
In this chapter, we will walk you through the setup of local monitoring for your validator node.

Installation

Make sure you download the latest releases. Please check Prometheus, Process exporter, and Grafana download pages. We will do our best to keep this guide updated but it wouldn't hurt to check if you are installing the latest versions.
Installation of these packages goes in 7 steps:
  • Download
  • Extract
  • Move the files to /usr/lib/bin
  • Create dedicated users
  • Create directories
  • Change the ownership of those directories
  • Cleanup

Prometheus

1
#download files
2
wget https://github.com/prometheus/prometheus/releases/download/v2.33.4/prometheus-2.33.4.linux-amd64.tar.gz
3
4
#extract
5
tar xvf prometheus-*.tar.gz
6
7
#move the files to /usr/lib/bin
8
sudo cp ./prometheus-2.33.4.linux-amd64/prometheus /usr/local/bin/
9
sudo cp ./prometheus-2.33.4.linux-amd64/promtool /usr/local/bin/
10
sudo cp -r ./prometheus-2.33.4.linux-amd64/consoles /etc/prometheus
11
sudo cp -r ./prometheus-2.33.4.linux-amd64/console_libraries /etc/prometheus
12
13
#create dedicated users
14
sudo useradd --no-create-home --shell /usr/sbin/nologin prometheus
15
16
#create directories
17
sudo mkdir /var/lib/prometheus
18
19
#change the ownership
20
sudo chown prometheus:prometheus /etc/prometheus/ -R
21
sudo chown prometheus:prometheus /var/lib/prometheus/ -R
22
sudo chown prometheus:prometheus /usr/local/bin/prometheus
23
sudo chown prometheus:prometheus /usr/local/bin/promtool
24
25
#cleanup
26
rm -rf ./prometheus*
Copied!

Node Exporter

1
#download files
2
wget https://github.com/prometheus/node_exporter/releases/download/v1.3.1/node_exporter-1.3.1.linux-amd64.tar.gz
3
4
#extract
5
tar xvf node_exporter-*.tar.gz
6
7
#move the files to /usr/lib/bin
8
sudo cp ./node_exporter-1.3.1.linux-amd64/node_exporter /usr/local/bin/
9
10
#create dedicated users
11
sudo useradd --no-create-home --shell /usr/sbin/nologin node_exporter
12
13
#change the ownership
14
sudo chown node_exporter:node_exporter /usr/local/bin/node_exporter
15
16
#cleanup
17
rm -rf ./node_exporter*
Copied!

Process Exporter

1
#download files
2
wget https://github.com/ncabatoff/process-exporter/releases/download/v0.7.10/process-exporter-0.7.10.linux-amd64.tar.gz
3
4
#extract
5
tar xvf process-exporter-*.tar.gz
6
7
#move the files to /usr/lib/bin
8
sudo cp ./process-exporter-0.7.10.linux-amd64/process-exporter /usr/local/bin/
9
10
#create dedicated users
11
sudo useradd --no-create-home --shell /usr/sbin/nologin process-exporter
12
13
#create directories
14
sudo mkdir /etc/process-exporter
15
16
#change the ownership
17
sudo chown process-exporter:process-exporter /etc/process-exporter -R
18
sudo chown process-exporter:process-exporter /usr/local/bin/process-exporter
19
20
#cleanup
21
rm -rf ./process-exporter*
Copied!

Alert Manager

1
#download files
2
wget https://github.com/prometheus/alertmanager/releases/download/v0.23.0/alertmanager-0.23.0.linux-amd64.tar.gz
3
4
#extract
5
tar xvf alertmanager-*.tar.gz
6
7
#move the files to /usr/lib/bin
8
sudo cp ./alertmanager-0.23.0.linux-amd64/alertmanager /usr/local/bin/
9
sudo cp ./alertmanager-0.23.0.linux-amd64/amtool /usr/local/bin/
10
11
#create dedicated users
12
sudo useradd --no-create-home --shell /usr/sbin/nologin alertmanager
13
14
#create directories
15
sudo mkdir /etc/alertmanager
16
sudo mkdir /var/lib/alertmanager
17
18
#change the ownership
19
sudo chown alertmanager:alertmanager /etc/alertmanager/ -R
20
sudo chown alertmanager:alertmanager /var/lib/alertmanager/ -R
21
sudo chown alertmanager:alertmanager /usr/local/bin/alertmanager
22
sudo chown alertmanager:alertmanager /usr/local/bin/amtool
23
24
#cleanup
25
rm -rf ./alertmanager*
Copied!

Grafana

1
sudo apt-get install -y adduser libfontconfig1
2
wget https://dl.grafana.com/oss/release/grafana_8.4.2_amd64.deb
3
sudo dpkg -i grafana_8.4.2_amd64.deb
4
5
sudo grafana-cli plugins install camptocamp-prometheus-alertmanager-datasource
6
sudo systemctl restart grafana-server
7
8
#cleanup
9
rm -rf ./grafana*
Copied!
Hope you are still with us? If yes, congrats. You should have a certificate :-).