diff --git a/integrations/Windows/markdown/README.md b/integrations/Windows/markdown/README.md index 99ed0f1d..74c80469 100644 --- a/integrations/Windows/markdown/README.md +++ b/integrations/Windows/markdown/README.md @@ -1,56 +1,15 @@ -## Windows Dashboard & Alerts +# Windows -使用[categraf](https://github.com/flashcatcloud/categraf)集Windows:win10/win2016基础监控指标数据: +categraf 不但支持 linux 监控数据采集,也支持 windows 监控数据采集,而且指标命名也是一样的,这样告警规则、仪表盘其实都可以复用。不需要对 windows 做额外处理。 -[Categraf安装文档(搜索Windows关键字)](https://flashcat.cloud/docs/content/flashcat-monitor/categraf/2-installation/) +## 安装 -### Categraf中conf/config.toml配置文件: +categraf 在 windows 下安装请参考这个 [文档](https://flashcat.cloud/docs/content/flashcat-monitor/categraf/2-installation/)。 -因为Categraf采集的指标并不是像Telegraf采集Windows的指标有win前缀,在Categraf里是没有的,是直接与linux的基础系统指标合并在一起的,而且在Windows下有一些指标没有的,比如FD、内核态等等指标。 +## 仪表盘 -合并在一起的好处是可以不用采集过多的冗余指标,浪费空间,减轻了时序存储的压力。 +linux、windows 仪表盘其实是可以复用的,只是两种操作系统个别指标不同。比如有些指标是 linux 特有的,有些指标是 windows 特有的。如果你想要分开查看,夜莺也内置了 windows 的仪表盘,克隆到自己的业务组下即可使用。 -如果有Linux、Windows共存的情况,为了使大盘可以区分属于哪个操作系统平台,我们使用全局标签来筛选即可。 - -Categraf的config.toml的简单配置,只需要修改3处即可; - -`Windows配置` - -```toml -... -# 此处label配置仅对Windows采集使用; -[global.labels] -platform="windows" -... -[[writers]] -url = "http://192.168.0.250:19000/prometheus/v1/write" -... -url = "http://192.168.0.250:19000/v1/n9e/heartbeat" -... -``` - -`Linux主机配置` - -```toml -... -# 此处label配置仅对Linux采集使用; -[global.labels] -platform="linux" -... -[[writers]] -url = "http://192.168.0.250:19000/prometheus/v1/write" -... -url = "http://192.168.0.250:19000/v1/n9e/heartbeat" -... -``` - -**注意:此处大盘仅对Windows做了label条件筛选,如果是Linux,需要单独在选择变量中加入platform='linux';如下:** - -`label_values(system_load1{platform="linux"},ident)` - -*如果不需要区分操作系统平台,也可以直接导入大盘使用* - -### Windows效果图 - -![windows](http://download.flashcat.cloud/uPic/windows.png) +## 告警规则 +夜莺虽然也内置了 windows 的告警规则,但因为 linux、windows 大部分指标都是一样的,就不建议为 windows 单独管理一份告警规则了。 diff --git a/integrations/ZooKeeper/markdown/README.md b/integrations/ZooKeeper/markdown/README.md index 2c69aa1c..8c3d5e9f 100644 --- a/integrations/ZooKeeper/markdown/README.md +++ b/integrations/ZooKeeper/markdown/README.md @@ -1,14 +1,18 @@ # zookeeper -**注意: >=3.6.0 zookeeper 版本内置 [prometheus 的支持](https://zookeeper.apache.org/doc/current/zookeeperMonitor.html),即,如果 zookeeper 启用了 prometheus,Categraf 可使用 prometheus 插件从这个 metrics 接口拉取数据即可;** -移植于 [dabealu/zookeeper-exporter](https://github.com/dabealu/zookeeper-exporter),适用于 `<3.6.0` 版本的 zookeeper, 原理就是利用 Zookeper 提供的四字命令(The Four Letter Words)获取监控信息; +注意: `>=3.6.0` zookeeper 版本内置 [prometheus 的支持](https://zookeeper.apache.org/doc/current/zookeeperMonitor.html),即,如果 zookeeper 启用了 prometheus,Categraf 可使用 prometheus 插件从这个 metrics 接口拉取数据即可。就无需使用 zookeeper 这个插件来采集了。 + +## 说明 + +categraf zookeeper 采集插件移植于 [dabealu/zookeeper-exporter](https://github.com/dabealu/zookeeper-exporter),适用于 `<3.6.0` 版本的 zookeeper, 原理就是利用 Zookeper 提供的四字命令(The Four Letter Words)获取监控信息。 需要注意的是,在 zookeeper v3.4.10 以后添加了四字命令白名单,需要在 zookeeper 的配置文件 `zoo.cfg` 中新增白名单配置: + ``` 4lw.commands.whitelist=mntr,ruok ``` -## Configuration +## 配置 zookeeper 插件的配置在 `conf/input.zookeeper/zookeeper.toml` 集群中的多个实例地址请用空格分隔: @@ -35,5 +39,5 @@ timeout = 10 ## 监控大盘和告警规则 -该 README 的同级目录下,提供了 dashboard.json 就是监控大盘的配置,alerts.json 是告警规则,可以导入夜莺使用。 +夜莺内置了 zookeeper 的监控大盘和告警规则,克隆到自己的业务组下即可使用。虽说文件名带有 `by_exporter` 字样,没关系,可以在 categraf 中使用。