node_exporter 自定义收集指标 textfile
指定textfile收集器读取指标文件的目录路径
systemctl status node_exporter.service
cat /lib/systemd/system/node_exporter.service
[Unit]
Description=node_exporter service
[Service]
User=root
ExecStart=/root/node_exporter/node_exporter \
--collector.textfile.directory=/seal/node_textfile
TimeoutStopSec=10
Restart=on-failure
RestartSec=5
[Install]
WantedBy=multi-user.target
systemctl daemon-reload
systemctl restart node_exporter.service
systemctl status node_exporter.service
curl http://localhost:9100/metrics