Setting Up Node Exporter¶
Download Node Exporter¶
Begin by downloading Node Exporter using the wget command:
wget https://github.com/prometheus/node_exporter/releases/download/v1.7.0/node_exporter-1.7.0.linux-amd64.tar.gz
Note: Ensure you are using the latest version of Node Exporter and the correct architecture build for your server. The provided link is for amd64. For the latest releases, check here - Prometheus Node Exporter Releases
Extract the Contents¶
After downloading, extract the contents with the following command:
Move the Node Exporter Binary¶
Change to the directory and move the node_exporter binary to /usr/local/bin:
Then, clean up by removing the downloaded tar file and its directory:
Create a Node Exporter User¶
Create a dedicated user for running Node Exporter:
Assign ownership permissions of the node_exporter binary to this user:
Configure the Service¶
To ensure Node Exporter automatically starts on server reboot, configure the systemd service:
Then, paste the following configuration:
[Unit]
Description=Node Exporter
Wants=network-online.target
After=network-online.target
[Service]
User=node_exporter
Group=node_exporter
Type=simple
ExecStart=/usr/local/bin/node_exporter
Restart=always
RestartSec=3
[Install]
WantedBy=multi-user.target
Enable and Start the Service¶
Reload the systemd daemon:
Enable the Node Exporter service:
Start the service:
To confirm the service is running properly, check its status: