Kusma is evolving fast, and so its monitoring tools.

We find recently that there is an easy and confortable dotexporter python script that will be usefull for most of you.

Table of contents

  1. Download dotexporter
  2. Create system service
  3. Enable and start service

Download dotexporter

Download it from here:

https://github.com/paritytech/dotexporter

Place your script in a common folder:  /usr/local/bin

Create system service

Create your systemd daemon:

vim /etc/systemd/system/dotexporter.service

[Unit]
Description=Dot Exporter

[Service]
ExecStart=/usr/bin/python3 /usr/local/bin/dotexporter.py 
Restart=always
# Restart service after 10 seconds if node service crashes
RestartSec=10
# Output to syslog
StandardOutput=syslog
StandardError=syslog
SyslogIdentifier=dotexporter

[Install]
WantedBy=multi-user.target

Enable and start service

Start your exporter service with:

systemctl daemon-reload && systemctl start dotexporter && systemctl enable dotexporter

After this you will have your node listening on port 8000 for your prometheus grafana/prometheus queries as we saw in previous articles.