配置单元连接失败

93ze6v8z  于 2021-06-26  发布在  Hive
关注(0)|答案(1)|浏览(348)

我试图连接到公共宇宙示例中的Hive,但失败了。
当我尝试通过java中的drivermanager获取连接时失败了。它给了我这个错误:

Exception in thread "main" java.sql.SQLException: Could not open connection to jdbc:hive2://cosmos.lab.fi-ware.org:10000/default: java.net.ConnectException: Conexión rehusada
at org.apache.hive.jdbc.HiveConnection.openTransport(HiveConnection.java:206)
at org.apache.hive.jdbc.HiveConnection.<init>(HiveConnection.java:178)
at org.apache.hive.jdbc.HiveDriver.connect(HiveDriver.java:105)
at java.sql.DriverManager.getConnection(DriverManager.java:571)
at java.sql.DriverManager.getConnection(DriverManager.java:215)
at com.isetic.cosmos.HiveConnectorTest.main(HiveConnectorTest.java:29)
Caused by: org.apache.thrift.transport.TTransportException: java.net.ConnectException: Conexión rehusada
at org.apache.thrift.transport.TSocket.open(TSocket.java:185)
at org.apache.thrift.transport.TSaslTransport.open(TSaslTransport.java:248)
at org.apache.thrift.transport.TSaslClientTransport.open(TSaslClientTransport.java:37)
at org.apache.hive.jdbc.HiveConnection.openTransport(HiveConnection.java:203)
... 5 more
Caused by: java.net.ConnectException: Conexión rehusada
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:339)
at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:200)
at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:182)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
at java.net.Socket.connect(Socket.java:579)
at org.apache.thrift.transport.TSocket.open(TSocket.java:180)
... 8 more

因此,我决定在cosmos示例中与我的用户连接,然后尝试启动hive server,结果出现以下错误:

Exception in thread "main" java.io.IOException: Mkdirs failed to create /tmp/hadoop-user
at org.apache.hadoop.util.RunJar.ensureDirectory(RunJar.java:100)
at org.apache.hadoop.util.RunJar.main(RunJar.java:144)

那么Hive怎么了??
它在几周前就可以工作了,而且代码还没有更改,所以我不知道问题出在哪里。

ev7lccsx

ev7lccsx1#

似乎是环境问题,可能是配置单元服务器2已关闭。通过登录服务器节点检查其运行状况,并查看java进程的状态。

相关问题