ubuntu安装node exporter

wget https://github.com/prometheus/node_exporter/releases/download/v0.17.0/node_exporter-0.17.0.linux-amd64.tar.gz 
mkdir /var/node_exporter 
tar xf node_exporter-0.17.0.linux-amd64.tar.gz -C /var/node_exporter/ 
rm node_exporter-0.17.0.linux-amd64.tar.gz 

tee /etc/supervisor/conf.d/node_exporter.conf <<-'EOF' 
[program:node_exporter] 
directory=/var/node_exporter/node_exporter-0.17.0.linux-amd64 
command=/var/node_exporter/node_exporter-0.17.0.linux-amd64/node_exporter 
user=root 
stdeer_logfile=/var/log/supervisor/node_explorer_eer.log 
stdout_logfile=/var/log/supervisor/node_explorer_out.log 
redirect_stderr=true 
EOF 

echo update node_explorter | supervisorctl 

1.安装前需要确认9100有无被占用。 
2.安装完毕后需要开放9100端口,并修改Prometheus配置文件才能展示结果 

©️2020 CSDN 皮肤主题: 大白 设计师:CSDN官方博客 返回首页