我下载的prometheus版本是2.3.2
wget https://github.com/prometheus/prometheus/releases/download/v2.3.2/prometheus-2.3.2.linux-amd64.tar.gz
untared 和 prometheus 已经作为服务运行。
我想使用 promtool 验证我的 Prometheus 警报管理器规则。
从下面的博客创建了一条规则。
https://petargitnik.github.io/blog/2018/01/04/how-to-write-rules-for-prometheus https://petargitnik.github.io/blog/2018/01/04/how-to-write-rules-for-prometheus
当我运行
promtool检查规则 /etc/prometheus/prometheus.rules.yml
它说,普罗米修斯没有安装,所以使用再次安装
获取普罗米修斯
但这是安装旧版本的 promtool,这里是版本详细信息:
root@UTVA-kafka-msg-size-2mb-02509:/home/ubuntu# promtool version
prometheus, version 0.16.2+ds (branch: debian/sid, revision: 0.16.2+ds-1ubuntu1)
build user: [email protected] /cdn-cgi/l/email-protection
build date: 20160408-04:15:29
go version: go1.6
Prometheus 版本 2 使用 yml 文件作为规则,较旧的版本使用不同的文件,因此我的 promtool 检查规则失败。
谁能建议如何升级最新的 promtool?
Thanks.