[
https://issues.apache.org/jira/browse/HIVE-26295?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17554987#comment-17554987
]
hansonhe commented on HIVE-26295:
---------------------------------
@ [~dengzh]
The following is the details with adding _--verbose_ at the end of beeline
command
22/06/16 17:25:23 INFO ZooKeeper: Session: 0x100c261eafc0081 closed
22/06/16 17:25:23 INFO ClientCnxn: EventThread shut down for session:
0x100c261eafc0081
Error: org.apache.hive.jdbc.ZooKeeperHiveClientException: Unable to read
HiveServer2 configs from ZooKeeper (state=,code=0)
java.sql.SQLException: org.apache.hive.jdbc.ZooKeeperHiveClientException:
Unable to read HiveServer2 configs from ZooKeeper
at org.apache.hive.jdbc.HiveConnection.<init>(HiveConnection.java:170)
at org.apache.hive.jdbc.HiveDriver.connect(HiveDriver.java:107)
at java.sql.DriverManager.getConnection(DriverManager.java:664)
at java.sql.DriverManager.getConnection(DriverManager.java:208)
at
org.apache.hive.beeline.DatabaseConnection.connect(DatabaseConnection.java:145)
at
org.apache.hive.beeline.DatabaseConnection.getConnection(DatabaseConnection.java:209)
at org.apache.hive.beeline.Commands.connect(Commands.java:1641)
at org.apache.hive.beeline.Commands.connect(Commands.java:1536)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at
org.apache.hive.beeline.ReflectiveCommandHandler.execute(ReflectiveCommandHandler.java:56)
at
org.apache.hive.beeline.BeeLine.execCommandWithPrefix(BeeLine.java:1384)
at org.apache.hive.beeline.BeeLine.dispatch(BeeLine.java:1423)
at org.apache.hive.beeline.BeeLine.connectUsingArgs(BeeLine.java:900)
at org.apache.hive.beeline.BeeLine.initArgs(BeeLine.java:795)
at org.apache.hive.beeline.BeeLine.begin(BeeLine.java:1048)
at
org.apache.hive.beeline.BeeLine.mainWithInputRedirection(BeeLine.java:538)
at org.apache.hive.beeline.BeeLine.main(BeeLine.java:520)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.apache.hadoop.util.RunJar.run(RunJar.java:318)
at org.apache.hadoop.util.RunJar.main(RunJar.java:232)
Caused by: org.apache.hive.jdbc.ZooKeeperHiveClientException: Unable to read
HiveServer2 configs from ZooKeeper
at
org.apache.hive.jdbc.ZooKeeperHiveClientHelper.configureConnParams(ZooKeeperHiveClientHelper.java:147)
at
org.apache.hive.jdbc.Utils.configureConnParamsFromZooKeeper(Utils.java:511)
at org.apache.hive.jdbc.Utils.parseURL(Utils.java:334)
at org.apache.hive.jdbc.HiveConnection.<init>(HiveConnection.java:168)
... 25 more
Caused by: org.apache.hive.jdbc.ZooKeeperHiveClientException: Unable to read
HiveServer2 uri from ZooKeeper:
at
org.apache.hive.jdbc.ZooKeeperHiveClientHelper.updateParamsWithZKServerNode(ZooKeeperHiveClientHelper.java:125)
at
org.apache.hive.jdbc.ZooKeeperHiveClientHelper.configureConnParams(ZooKeeperHiveClientHelper.java:145)
... 28 more
Beeline version 3.1.2 by Apache Hive
> Hive LB based on zookeeper occured some probability of connect failed
> ---------------------------------------------------------------------
>
> Key: HIVE-26295
> URL: https://issues.apache.org/jira/browse/HIVE-26295
> Project: Hive
> Issue Type: Bug
> Affects Versions: 3.1.2
> Reporter: hansonhe
> Priority: Major
>
> (1) I set LB properties in hive-site.xml
> hive.server2.support.dynamic.service.discovery=true
> hive.server2.active.passive.ha.enable=false
> (2) My hive production cluster info
> hive version: Apache 3.1.2
> hadoop version: Apache 3.1.4
> zookeeper version: Apache 3.5.9
> URL:
> jdbc:hive2://host1:2181,host2:2181,host3:2181/;serviceDiscoveryMode=zooKeeper;zooKeeperNamespace=hiveserver2
> my hive cluster have 3 hiveserver2 : host1:10000,host2:10000,host3:10000
> (3)After lots of test connect to use beeline -u '${URL}' -n 'hive' -p 'xxxx'
> , some probability of connect failured or connect success.When connect
> success,it can connect anyone of 3 hiveserver2 randomly and successfully.
> When connect failed,failed logs as following :
> 22/06/07 11:14:59 INFO X509Util: Setting -D
> jdk.tls.rejectClientInitiatedRenegotiation=true to disable client-initiated
> TLS renegotiation
> 22/06/07 11:14:59 INFO ClientCnxnSocket: jute.maxbuffer value is 4194304 Bytes
> 22/06/07 11:14:59 INFO ClientCnxn: zookeeper.request.timeout value is 0.
> feature enabled=
> 22/06/07 11:14:59 INFO ClientCnxn: Opening socket connection to server
> host3/10.2.52.73:2181. Will not attempt to authenticate using SASL (unknown
> error)
> 22/06/07 11:14:59 INFO ClientCnxn: Socket connection established, initiating
> session, client: /10.2.52.110:61210, server:
> sh1-bigdata-master03/10.2.52.73:2181
> 22/06/07 11:14:59 INFO ClientCnxn: Session establishment complete on server
> host3/10.2.52.73:2181, sessionid = 0x301b42644c8001c, negotiated timeout =
> 60000
> 22/06/07 11:14:59 INFO ConnectionStateManager: State change: CONNECTED
> 22/06/07 11:14:59 INFO CuratorFrameworkImpl: backgroundOperationsLoop exiting
> 22/06/07 11:14:59 INFO ZooKeeper: Session: 0x301b42644c8001c closed
> 22/06/07 11:14:59 INFO ClientCnxn: EventThread shut down for session:
> 0x301b42644c8001c
> Error: org.apache.hive.jdbc.ZooKeeperHiveClientException: Unable to read
> HiveServer2 configs from ZooKeeper (state=,code=0)
> Beeline version 3.1.2 by Apache Hive
--
This message was sent by Atlassian Jira
(v8.20.7#820007)