kafka监控
2024-08-25 14:41:42
做kafka相关项目,需要用到监控的东东,找到了两个方法
第一个:
http://quantifind.com/KafkaOffsetMonitor/
非常容易上手,效果也直观,可以显示各个topic consumer的offset broker存储log的长度
不过发现一个bug就是当 consumer没有commit offset的时候 这个topic就不会显示它的消费情况
使用方法就是直接启动一个jar包 配好zookeeper就好了
第二个比较直接:就是kafka直接提供jmx接口进行监控
首先需要把jmx打开 方法参照了:
http://blogs.impetus.com/big_data/big_data_technologies/kafka-monitoring-using-jmx-jmxtrans.do
Step-I: Setup JMXTrans on all the machines of the Kafka cluster as done on the Storm cluster in the previous post.Step-II: In the kafka setup, edit “kafka-run-class.sh” script file by adding the following line to it:KAFKA_JMX_OPTS="-Dcom.sun.management.jmxremote=true -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false "Step-III: Also, edit the “kafka-server-start.sh” script file present in the kafka setup to set the JMX port to 9999 by adding the following line:export JMX_PORT=${JMX_PORT:-9999}
apache的wiki推荐了四种jmx reporter
本人实践中采用了jmxtrans 就是将jmx的信息以json格式汇报出来 比较好方便集成到现有的监控系统当中
最新文章
- 简单代码在ABAP中实现声音的播放
- 大家一起和snailren学java-(13)字符串
- PHP中array_chunk的用法
- [转帖] CvMat,Mat和IplImage之间的转化和拷贝
- ArcEngine开发异常:无当前记录
- windows 测试数据库的连接状况-udl方法
- iOS开发-GCD和后台处理
- ichartjs
- Struts2中的验证框架
- 基于Flink秒级计算时CPU监控图表数据中断问题
- python 09
- appium---第二个脚本,定位页面元素
- .NET WebService 入门
- SpringBoot整合MyBatis(XML)
- Flask系列06--(中间件)Flask的特殊装饰器 before_request,after_request, errorhandler
- IDEA2018.1安装配置文档
- 推荐一些socket工具,TCP、UDP调试、抓包工具
- Oracle数据库order by排序查询分页比不分页还慢问题解决办法
- e668. 在一组像素中创建缓冲图像
- Qt Pro文件与Qt模块启用
热门文章
- codeforces --- 115A
- robotium源码方法备注---clicker.java
- Longest Consecutive Sequence——Leetcode
- Tree2cycle
- Redis教程03——Redis 发布/订阅(Pub/Sub)
- 【转载】nginx 并发数问题思考:worker_connections,worker_processes与 max clients
- Hashtable映射数据库字段
- .net对js和css、img剥离项目进行压缩优化、cdn加速
- DevExpress LookUpEdit 下拉框基本操作
- 【转】Android通过Wifi来调试你的应用