系统相关
首页 > 系统相关> > Prometheus监控linux

Prometheus监控linux

作者:互联网

node_exporter:用于监控Linux系统的指标采集器。

常用指标:

•CPU

•内存

•硬盘

•网络流量

•文件描述符

•系统负载

•系统服务数据接口:http://IP:9100

使用文档:

https://prometheus.io/docs/guides/node-exporter/

GitHub:

https://github.com/prometheus/node_exporter

在Prometheus配置文件添加被监控端:

scrape_configs:

-job_name: 'Linux Server'

basic_auth:

username: prometheus

password: 123456

static_configs:

-targets: ['192.168.121.132:9100']

自启动:

[root@k8s-2 node_exporter]# vi /usr/lib/systemd/system/node_exporter.service

[Unit]
Description=node_exporter

[Service]
ExecStart=/opt/monitor/node_exporter/node_exporter --web.config=/opt/monitor/node_exporter/config.yml
ExecReload=/bin/kill -HUP $MAINPID
KillMode=process
Restart=on-failure

[Install]
WantedBy=multi-user.target

标签:node,exporter,prometheus,9100,Prometheus,监控,linux,config
来源: https://www.cnblogs.com/jamespeng/p/14720400.html