Official documents:
http://www.kafka-eagle.org/articles/docs/installation/linux-macos.html
Download Kafka Eagle
https://link.zhihu.com/?target=http%3A//download.smartloli.org
kafka-eagle-bin-1.2.3.tar.gz Recovery Linux
解压 tar -xvf kafka-eagle-bin-1.2.3.tar.gz
Double naming: mv kafka-eagle-bin-1.2.3 kafka-eagle
Enter the Kafka Eagle directory, enter the conf directory and modify the content of the system-config.properties configuration file as follows
######################################
# 配置多个Kafka集群所对应的Zookeeper
######################################
kafka.eagle.zk.cluster.alias=cluster1,cluster2
cluster1.zk.list=dn1:2181,dn2:2181,dn3:2181
cluster2.zk.list=tdn1:2181,tdn2:2181,tdn3:2181
######################################
# 设置Zookeeper线程数
######################################
kafka.zk.limit.size=25
######################################
# 设置Kafka Eagle浏览器访问端口
######################################
kafka.eagle.webui.port=8048
######################################
# 如果你的offsets存储在Kafka中,这里就配置
# 属性值为kafka,如果是在Zookeeper中,可以
# 注释该属性。一般情况下,Offsets的也和你消
# 费者API有关系,如果你使用的Kafka版本为0.10.x
# 以后的版本,但是,你的消费API使用的是0.8.2.x
# 时的API,此时消费者依然是在Zookeeper中
######################################
cluster1.kafka.eagle.offset.storage=kafka
#######################################
如果你的集群一个是新版本(0.10.x以上),
# 一个是老版本(0.8或0.9),可以这样设置,
# 如果都是新版本,那么可以将值都设置成kafka
######################################
cluster2.kafka.eagle.offset.storage=zookeeper
######################################
# 是否启动监控图表,默认是不启动的
######################################
kafka.eagle.metrics.charts=false
######################################
# 在使用Kafka SQL查询主题时,如果遇到错误,
# 可以尝试开启这个属性,默认情况下,不开启
######################################
kafka.eagle.sql.fix.error=false
######################################
# 邮件服务器设置,用来告警
######################################
kafka.eagle.mail.enable=false
kafka.eagle.mail.sa=
kafka.eagle.mail.username=
kafka.eagle.mail.password=
kafka.eagle.mail.server.host=
kafka.eagle.mail.server.port=
######################################
# 设置告警用户,多个用户以英文逗号分隔
######################################
[email protected]
######################################
# 超级管理员删除主题的Token
######################################
kafka.eagle.topic.token=keadmin
######################################
# 如果启动Kafka SASL协议,开启该属性
######################################
kafka.eagle.sasl.enable=false
kafka.eagle.sasl.protocol=SASL_PLAINTEXT
kafka.eagle.sasl.mechanism=PLAIN
######################################
# Kafka Eagle默认存储在Sqlite中,如果要使用
# MySQL可以替换驱动、用户名、密码、连接地址
######################################
#kafka.eagle.driver=com.mysql.jdbc.Driver
#kafka.eagle.url=jdbc:mysql://127.0.0.1:3306/ke?useUnicode=true&characterEncoding=UTF-8&zeroDateTimeBehavior=convertToNull
#kafka.eagle.username=root
#kafka.eagle.password=123456
kafka.eagle.driver=org.sqlite.JDBC
kafka.eagle.url=jdbc:sqlite:/Users/dengjie/workspace/kafka-egale/db/ke.db
kafka.eagle.username=root
kafka.eagle.password=root
Need to configure mysql or Sqlite, just choose one
Install JDK
cd /usr/java
tar -zxvf jdk-xxxx.tar.gz
mv jdk-xxxx jdk1.8
or:
centos:yum install java-11-openjdk
ubuntu:apt install default-jdk
默安装默认的目录为:/usr/lib/jvm/
判断java是否安装成功:java -version
Configure environment variables
# java所在的目录 (不知道在哪里可以百度下)
export JAVA_HOME=/usr/
#kafka-eagle所在的目录
export KE_HOME=/home/kafka-eagle
export PATH=$PATH:$JAVA_HOME/bin:$KE_HOME/bin
source ~/.bash_profile
Start Kafka Eagle
After the configuration is complete, you can execute the Kafka Eagle script ke.sh. If you execute it for the first time, you need to give the script execution permission, the command is as follows:
chmod +x $KE_HOME/bin/ke.sh
In the ke.sh script, the following commands are supported:
Command description
Seeing here does not mean that the startup is successful! ! !
Seeing here does not mean that the startup is successful! ! !
Seeing here does not mean that the startup is successful! ! !
Use ./bin/ke.sh status to check the status, it is running.
reference:
https://www.cnblogs.com/smartloli/p/9371904.html
https://zhuanlan.zhihu.com/p/110022903