Introduction: there are many problems about hosts on the Internet. After testing, I found out that it is not. After testing by myself, I introduced three solutions to most problems:
1. Firewall port not opened or closed
firewall generally local test will be closed, the line is generally open, it is recommended to add port
add port:
# --permanent 为永久添加,不指定此参数重启后失效
firewall-cmd --zone=public --add-port=9092/tcp --permanent
delete port:
firewall-cmd --zone=public --remove-port=80/tcp --permanent
view all ports:
firewall-cmd --zone=public --list-ports
view specified port:
firewall-cmd --zone= public --query-port=9092/tcp
view port status:
netstat -tunlp
overload:
firewall-cmd --reload
firewall command:
#开启防火墙
service firewalld start
#启用防火墙
service firewalld enable (永久生效)
#关闭防火墙
service firewalld stop (重启后失效)
#禁用防火墙
service firewalld disable (永久生效)
#重启防火墙
service firewalld restart
#查看状态
service firewalld status
2. Kafka service entry address not specified
edit the server.properties in the config directory of kafka, and add the address of the service entry to the external service:
注意:此ip为kafka所在主机的ip地址
listeners=PLAINTEXT://192.168.5.228:9092
3. The kafka version in the project is inconsistent with the kafka version installed on the server
modify maven pom. XML file, specify the corresponding kafka coordinates,
I installed kafka_2.12-2.1.0, the corresponding coordinates are:
<dependency>
<groupId>org.apache.kafka</groupId>
<artifactId>kafka_2.11</artifactId>
<version>0.10.0.0</version>
</dependency>
div>
Read More:
- kafka-eagle-2.0.3:Note: Kafka version is – or JMX Port is -1 maybe kafka broker jmxport disable.
- KAFKA – ERROR Failed to write meta.properties due to (kafka.server.BrokerMetadataCheckpoint)
- Kafka : WARN Error while fetching metadata with correlation id xx : {=UNKNOWN_TOPIC_OR_PARTITION}
- K8s deployment Kafka has been reporting errors.
- Kafka startup failed with an error of inconsistentclusteridexception
- Kafka reported error shutdown broker because all log dirs in… Have failed
- spark SQL Export Data to Kafka error [How to Solve]
- Kafka prompts no brokers found when trying to rebalance
- Running course of Kafka in Windows Environment
- Centos7 installing Kafka
- Kafka opens JMX port and reports that the error port is occupied
- [Solved] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.22.2:test
- “[warning] failed to retrieve plugin descriptor for caused by Maven security agent settings org.apache.maven . plugins:… “
- Caused by: org.apache.ibatis.builder.BuilderException: Error resolving class. Cause: org.apache.ibat
- TIDB-kafka server: Message was too large, server rejected it to avoid allocation error
- MySQL driver compiling method of QT under windows and solutions to abnormal errors
- Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.22.1:test (default-test)
- When I first learned mybatis org.apache.ibatis . binding.BindingException report errors
- How to Fix Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.7.0:compile
- Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.1:compile (default-compile)