Created
May 12, 2020 09:32
-
-
Save Tumar/18ef41165eda6f9990412b49a84dccae to your computer and use it in GitHub Desktop.
Install prometheus node exporter
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Download and unpack | |
curl -LO https://github.com/prometheus/node_exporter/releases/download/v0.18.1/node_exporter-0.18.1.linux-amd64.tar.gz | |
tar -xvf node_exporter-0.18.1.linux-amd64.tar.gz | |
sudo mv node_exporter-0.18.1.linux-amd64/node_exporter /usr/local/bin | |
# Add user | |
sudo useradd -rs /bin/false node_exporter | |
# Configure service | |
sudo vi /etc/systemd/system/node_exporter.service | |
### Configuration | |
[Unit] | |
Description=Node Exporter | |
After=network.target | |
[Service] | |
User=node_exporter | |
Group=node_exporter | |
Type=simple | |
ExecStart=/usr/local/bin/node_exporter | |
[Install] | |
WantedBy=multi-user.target | |
# Start exporter | |
sudo systemctl daemon-reload | |
sudo systemctl start node_exporter |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment