grafana+prometheus监控linux指标

先查看linux架构

root@node-0006 node_exporter-1.6.1.linux-amd64\]# uname -m aarch64 我服务器是**ARM 架构** 所以是下载适用于 ARM64 的 Node Exporter: 新建一个文件夹 进入 ``` wget https://github.com/prometheus/node_exporter/releases/download/v1.6.1/node_exporter-1.6.1.linux-arm64.tar.gz ``` ``` tar -xzf node_exporter-1.6.1.linux-arm64.tar.gz cd node_exporter-1.6.1.linux-arm64 ``` 确保 `node_exporter` 文件具有可执行权限: chmod +x node_exporter 启动 Node Exporter: ``` ./node_exporter ``` 如果看到大量以 `node_` 开头的指标,表示 Node Exporter 已成功运行。 ![](https://i-blog.csdnimg.cn/direct/075264e3ec6d4357a5a4e67f2d3fe2ce.png) 可以用目标服务器 curl http://localhost:9100/metrics 如果服务器是内网,用nginx配置 转发 location /linux_metrics { proxy_pass http://服务器ip:9100/metrics; } 这样就用域名访问https://域名/linux_metrics scrape_configs: - job_name: 'prometheus' static_configs: - targets: \['localhost:9090'

  • job_name: 'linux_node_exporter'

metrics_path: '/linux_metrics'

scheme: https

static_configs:

  • targets: ['域名']

prometheus有指标了就行

grafana添加linux面板

相关推荐
一叶之秋14123 小时前
Linux基础IO
linux·运维·服务器
longerxin20206 小时前
在 Linux 上使用 SCP 将文件传输到 Windows(已开启 SSH)
linux·运维·ssh
王正南10 小时前
kali-linux 虚拟机连接安卓模拟器
android·linux·运维·虚拟机连接模拟器·安卓模拟器,linux虚拟机
吳所畏惧10 小时前
Linux环境/麒麟V10SP3下离线安装Redis、修改默认密码并设置Redis开机自启动
linux·运维·服务器·redis·中间件·架构·ssh
yueguangni10 小时前
sysstat 版本 10.1.5 是 CentOS 7 的默认版本,默认情况下确实不显示 %wait 字段。需要升级到新版sysstat
linux·运维·centos
萧曵 丶12 小时前
Linux 业务场景常用命令详解
linux·运维·服务器
豆是浪个12 小时前
Linux(Centos 7.6)命令详解:ps
linux·windows·centos
Run_Teenage13 小时前
Linux:深刻理解缓冲区
linux
youxiao_9013 小时前
kubernetes 概念与安装(一)
linux·运维·服务器
凡梦千华13 小时前
logrotate日志切割
linux·运维·服务器