Phoenix 无法启动报错: java.net.BindException: Address already in use

一、问题描述

i. 登录Ambari发现有一个节点的 Phoenix 无法启动

Phoenix 无法启动报错: java.net.BindException: Address already in use_第1张图片

Phoenix 无法启动报错: java.net.BindException: Address already in use_第2张图片

ii. 在Ambari上点击“Start”,监控 Phoenix 日志文件

Phoenix 无法启动报错: java.net.BindException: Address already in use_第3张图片

iii. Phoenix 日志如下:

[root@zwlbs3 ~]# tail -f /var/log/hbase/phoenix-hbase-server.log

------------------------ 日志信息如下 -----------------------
2019-07-18 11:20:56,621 WARN org.apache.hadoop.util.NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicable
2019-07-18 11:20:56,751 INFO org.apache.calcite.avatica.metrics.MetricsSystemLoader: No metrics implementation available on classpath. Using No-op implementation
2019-07-18 11:20:56,765 INFO org.apache.phoenix.shaded.org.eclipse.jetty.util.log: Logging initialized @1113ms
2019-07-18 11:20:56,975 INFO org.apache.phoenix.shaded.org.eclipse.jetty.server.Server: jetty-9.2.z-SNAPSHOT
2019-07-18 11:20:57,014 WARN org.apache.phoenix.shaded.org.eclipse.jetty.util.component.AbstractLifeCycle: FAILED ServerConnector@2e6a8155{HTTP/1.1}{0.0.0.0:8765}: java.net.BindException: Address already in use
java.net.BindException: Address already in use
at sun.nio.ch.Net.bind0(Native Method)
at sun.nio.ch.Net.bind(Net.java:433)
at sun.nio.ch.Net.bind(Net.java:425)
.......

二、解决办法

注:上面的错误表示 8765 端口已经被另一个应用程序使用。

查询端口并kill掉

[root@zwlbs3 ~]# netstat -ntlp | grep 8765
tcp6   0   0   :::8765       :::*    LISTEN   1038/java
[root@zwlbs3 ~]# kill -9 1038

再次启动 Phoenix,重复1.2步骤即可。

你可能感兴趣的:(Phoenix 无法启动报错: java.net.BindException: Address already in use)