Node_exporter安装配置

一、什么是Node_exporter?

监控服务器CPU、内存、磁盘、I/O等信息,node_exporter的作用是用于机器系统数据收集。

二、怎么安装Node_expoter?

1.下载node_exporter安装包(linux版)到 /opt/minitor/node_exporter 。
 
2.运行 tar -zxvf node_exporter-0.16.0.linux-amd64.tar.gz ,解压文件到当前目录。
 
3.执行 vim /opt/minitor/prometheus/prometheus.yml,添加以下配置文件(红色部分):
scrape_configs:
  # The job name is added as a label `job=<job_name>` to any timeseries scraped from this config.
  - job_name: 'prometheus'
 
    # metrics_path defaults to '/metrics'
    # scheme defaults to 'http'.
 
    static_configs:
      - targets: ['ip:9090']
        labels:
          instance: prometheus
  - job_name: node
    static_configs:
      - targets: ['ip:9100']
        labels:
          instance: node
 
4.启动 node_exporter
nohup ./node_exporter &     
 
5.去prometheus中查看node的状态
 
6.在grafana中查看配置状态(推荐使用8919)
 
 
7.效果图如下:

 

posted @ 2020-11-09 23:04  Fire♪一度  阅读(1301)  评论(0编辑  收藏  举报