Skip to content

Latest commit

 

History

History

lab05

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 

实验五、NodeExporter系统监控实验

实验步骤

1. 下载和运行wmi-exporter

下载wmi_exporter-amd64,并解压到本地目录

运行wmi-exporter

./wmi_exporter.exe

校验metrics端点

http://localhost:9182/metrics

2. 配置和运行Promethus

Prometheus安装目录下

prometheus.yml 中添加针对wmi-exporter的监控job

  - job_name: 'wmi-exporter'
    static_configs:
      - targets: ['localhost:9182']

运行Prometheus

./prometheus.exe

访问Prometheus UI

http://localhost:9090

通过Prometheus->Statusconfigurationtargets校验配置正确

通过Prometheus->Graph查询wmi-exporter在UP1状态

up{job="wmi-exporter"}

3. Grafana Dashboard for wmi-exporter

在Grafana安装目录下启动Grafana服务器

./bin/grafana-server.exe

登录Grafana UI(admin/admin)

http://localhost:3000

通过Grafana的**+**图标导入(Import) wmi-exporter dashboard:

  • grafana id = 2129
  • 注意选中prometheus数据源

查看Windows Node dashboard。

4. 参考

Grafana Dashboard仓库

https://grafana.com/dashboards