作者:U友50054453 | 来源:互联网 | 2023-09-09 16:44
Prometheus采集主机监控参考部署下载,图形生成系统安装GrafanadownloadWindows参考图形生成参考win_exporterLinux参考no
Prometheus采集主机监控参考部署下载,图形生成
系统 | 安装 | Grafana | download |
Windows | 参考 | 图形生成参考 | win_exporter |
Linux | 参考 | node_exporter |
Mysql | 参考 | Mysql_exporter |
SQL Server | 参考 | SQL exporter |
Redis | 参考 | Redis_exporter |
cadvisor | 参考 | cadvisor |
snmp_exporter | 参考 | 图形展示在测试中 | snmp_exporter |
download cadvisor
- cadvisor采集数据
- 端口 8082
- go版本不要太高(1.14+1.18以下)默认系统yum 安装的是1.16版本我的系统是Red Hat 8
cadvisor 一键docker监控安装脚本
vim /cadvisor.sh
#!/bin/sh
# -*- coding: utf-8 -*-
# Date: 2022/11/23
# CIASM CSDNecho "Dependent installation"
sleep 2
yum install go gcc make -yecho "download cadvisor"
sleep 2
wget -N -P /root/ https://github.com/google/cadvisor/archive/refs/tags/v0.46.0.tar.gzecho "Compile and install & config"
sleep 2
tar xvf /root/v0.46.0.tar.gz -C /usr/local/
ln -s /usr/local/cadvisor-0.46.0 /usr/local/cadvisor
cd /usr/local/cadvisor/ && go env -w GOPROXY=https://goproxy.cn && go get -d github.com/google/cadvisor && make buildecho "cadvisor Start Service"
sleep 2
cat >>/usr/lib/systemd/system/cadvisor.service<[Unit]
Description=cadvisor
Documentation=https://github.com/google/cadvisor/tree/master/docs
After=network.target[Service]
Type=simple
ExecStart=/usr/local/cadvisor/_output/cadvisor -port 8082
Restart=on-failure[Install]
WantedBy=multi-user.target
EOFecho " cadvisor Example Set the automatic startup service"
sleep 2
systemctl daemon-reload && systemctl enable --now cadvisor
执行部署
sh /cadvisor.sh
页面访问