关闭

Kafka-0.7.2常用的命令(帮助自己记忆)

730人阅读 评论(0) 收藏 举报
分类:

wiki地址

                <1> http://kafka.apache.org/07/quickstart.html;

                <2>http://kafka.apache.org/documentation.htm;


启动kafkabin/kafka-server-start.shconfig/server.properties

kafkabin/kafka-console-producer.sh--zookeeper localhost:2181 --topic test

kafkabin/kafka-console-consumer.sh--zookeeper localhost:2181 --topic test --from-beginning


配置文件:server.properties(日志保留的时间设置,全局和topic):

log.retention.hours 24 * 7 The number of hours to keep a log segment before it is deleted, i.e. the default data retention window for all topics. Note that if both log.retention.hours and log.retention.bytes are both set we delete a segment when either limit is exceeded.
log.retention.hours.per.topic "" A per-topic override for log.retention.hours.


0
0

查看评论
* 以上用户言论只代表其个人观点,不代表CSDN网站的观点或立场
    个人资料
    • 访问:13176次
    • 积分:202
    • 等级:
    • 排名:千里之外
    • 原创:7篇
    • 转载:1篇
    • 译文:0篇
    • 评论:1条
    文章分类