DCMonitor - 一个简单轻量的数据中心监控工具

jopen 9年前

一个简单轻量的数据中心监控工具,包括了 Zookeeper, Kafka, Druid. Motivated by KafkaOffsetMonitor,但是更快和更加稳定。

它采用java编写,使用 InfluxDB v0.9 作为历史指标的存储。

Zookeeper monitor

DCMonitor - 一个简单轻量的数据中心监控工具

Kafka monitor

DCMonitor - 一个简单轻量的数据中心监控工具 DCMonitor - 一个简单轻量的数据中心监控工具

Dependences

  • Run
  • Compilation
    • java(1.6 or later)

Installation

  • Set up your Zookeeper, Kafka, Druid(If you have) for monitoring.
  • Set up InfluxDB v0.9.

    • install influxdb

    If v0.9 haven't been finally released by now, you may have to compile it yourself. Check its doc to see how to compile InfluxDB.

    • create a database for DCMonitor, can be done by sending HTTP POST requests like:
    curl -G 'http://192.168.10.60:8086/query?u=root&p=root' --data-urlencode "q=CREATE database dcmonitor"    curl -G 'http://192.168.10.60:8086/query?u=root&p=root&db=dcmonitor' --data-urlencode "q=CREATE RETENTION POLICY seven_days ON dcmonitor DURATION 168h REPLICATION 1 DEFAULT"

    here192.168.10.60:8086is where InfluxDB installed, and168hshows we only keep the last 7 days historical metrics. Check here for detail.

  • Compile & deploy DCMonitor

    • compile
    git clone git@github.com:shunfei/DCMonitor.git  cd DCMonitor  ./build.sh

    Then atargetfolder will be generated under root folder.

    • deploy

    You only need to deploytarget,run.sh,configto target machine.

    Modify configurations inconfig/config.json.

    Runrun.sh, if every thing is fine, visithttp://hostname:8075to enjoy!

项目主页:http://www.open-open.com/lib/view/home/1427336102902