- In/Out消息统计
- Topic增量数据排名
- Consumer延迟实时排名
- 可查看每个Topic Partition的Logsize Offsets Lag数据
- 实时获取指定Group的Logsize Offsets Lag
- 可定制的历史数据存储时间
- 集群各个节点性能数据
- 单个Server性能数据与该Server的当前活跃客户端
- 展示指定znode数据(zookeeper get操作)
- 可定制的历史数据存储时间
/api/v1/kafka
参数
- cluster kafka.yaml中配置的Kafka集群名称
- topic Kafka Topic
- group Consumer Group
curl "http://127.0.0.1:8080/api/v1/kafka?cluster=myCluster&topic=myTopic&group=myGroup"
/api/v1/zookeeper
参数
- cluster
- server
curl "http://127.0.0.1:8080/api/v1/zookeeper?cluster=myCluster&server=10.0.0.1"
cd kzmonitor; pip install -r requirements.txt
- etc/server.conf 控制数据采集间隔与存储时间等
- etc/kafka.yaml 监控Kafka集群配置
- etc/zookeeper.yaml 监控Zookeeper集群配置
cd kzmonitor; nohup python kzmonitor.py &> /dev/null &
$ docker build -t kzmonitor .
Or
$ docker pull liubin/kzmonitor
Init config files
$ docker run -v `pwd`/tmp/etc:/tmp/etc --rm kzmonitor cp -r /kzmonitor/etc /tmp
Edit config files
$ vi tmp/etc/kafka.yaml
$ vi tmp/etc/zookeeper.yaml
$ mkdir -p tmp/data/{kafka,zookeeper}
$ docker run -p 8088:80 \
-v `pwd`/tmp/etc:/kzmonitor/etc \
-v `pwd`/tmp/data:/kzmonitor/data \
-e PORT=8088 \
-e USER=aster \
-e PASS=abcde \
kzmonitor
$ docker logs -f kzmonitor
Envs for basic auth:
PORT
: If changed inetc/server.conf
, default is8080
;USER
: User for basic auth, defaultadmin
;PASS
: Password for basic auth, default567