DevOps Tools/Prometheus/Exporter

From r00tedvw.com wiki
Jump to: navigation, search

Overview | Prometheus Server | Prometheus Node Exporter

Contents

Overview

Metric collector. The prometheus server will have ingress connections to each of the node exporters in order to scrape a file that is hosted on each node exporter.

CentOS7 Installation

Create dependencies

~$ sudo yum install -y wget curl
~$ sudo groupadd --system prometheus
~$ sudo useradd -s /sbin/nologin --system -g prometheus prometheus

Download and setup

~$ curl -s https://api.github.com/repos/prometheus/node_exporter/releases/latest | grep browser_download_url | grep linux-amd64 | cut -d '"' -f 4 | wget -qi -
~$ tar xvf node_exporter*.tar.gz
~$ cd node_exporter*/
~$ sudo cp node_exporter /usr/local/bin

Setup Firewall rules

~$ sudo firewall-cmd --zone=public --permanent --add-port=9100/tcp 
~$ sudo firewall-cmd --reload

Create systemd service

~$ sudo vim /etc/systemd/system/node-exporter.service

systemd service

[Unit]
Description=Node Exporter
After=network.target

[Service]
User=prometheus
Type=simple
ExecStart=/usr/local/bin/node_exporter

[Install]
WantedBy=multi-user.target
~$ sudo systemctl daemon-reload
~$ sudo systemctl start node-exporter
~$ sudo systemctl enable node-exporter

Test

Test connection to the server running Prometheus Node Exporter on port 9100

Personal tools
Namespaces

Variants
Actions
Navigation
Mediawiki
Confluence
DevOps Tools
Ubuntu
Ubuntu 22
Mac OSX
Oracle Linux
AWS
Windows
OpenVPN
Grafana
InfluxDB2
TrueNas
OwnCloud
Pivotal
osTicket
OTRS
phpBB
WordPress
VmWare ESXI 5.1
Crypto currencies
HTML
CSS
Python
Java Script
PHP
Raspberry Pi
Canvas LMS
Kaltura Media Server
Plex Media Server
MetaSploit
Zoneminder
ShinobiCE
Photoshop CS2
Fortinet
Uploaded
Certifications
General Info
Games
Meal Plans
NC Statutes
2020 Election
Volkswagen
Covid
NCDMV
Toolbox