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:
- The solution of centos7’s inaccessibility after installing nginx
- The solution of centos7 in VMware virtual machine unable to access after installing nginx
- Firewall CMD command in CentOS 7
- Linux turn off enable firewall command
- [Solved] Rabbitmq Warning: java.net.SocketException: socket closed
- Error condition on socket for Sync: connection reused
- Solution to a Jenkins serious error recorded by automation platform
- Centos7 viewing and closing firewalls
- Solution to redis error in CentOS of idea connected virtual machine
- Navicat remote connection SQL Server 2014 express report 08001 error
- Fast DFS small demo report error org.csource.common .MyException: getStoreStorage fail, errno code: 2
- kafka-eagle-2.0.3:Note: Kafka version is – or JMX Port is -1 maybe kafka broker jmxport disable.
- Solve the problem of Failed to load resource: net::ERR_CONNECTION_REFUSED
- Common command of docker
- Nmap enumerates remote machine open ports
- Tns-03505: the ultimate solution to failed to resolve name
- Centos7 view and close firewall
- Win10 (1703) app store download app prompt error code 0x80d0000a
- [Solved] Error in registering Eureka for spring cloud micro service: classnotfoundexception: org.apache.http.conn.scheme.schemeregistry
- Oracle Data Guard Ping [arc2]: heartbeat failed to connect to standby “. Error is 12514 fault analysis