Our Community is getting an upgrade! To get everything ready for the relaunch, we’ll be placing the site in read-only mode starting September 21st.
We really appreciate your understanding while we get things set up behind the scenes. Catch up on all the exciting details about the move here.
Need help or have questions? Drop us a line at [email protected]

Archives of Support Questions (Read Only)

This is an archived board for historical reference. Information and links may no longer be available or relevant
Announcements
This board is archived and read-only for historical reference. To ask a new question, please post a new topic on the appropriate active board.

while connecting to hiveserver2 from my java client I am getting this exception

avatar

org.apache.thrift.protocol.TProtocolException: Required field 'serverProtocolVersion' is unset! Struct:TOpenSessionResp(status:TStatus(statusCode:SUCCESS_STATUS), serverProtocolVersion:null, sessionHandle:TSessionHandle(), configuration:{}) at org.apache.hive.service.cli.thrift.TOpenSessionResp.validate(TOpenSessionResp.java:578) at org.apache.hive.service.cli.thrift.TOpenSessionResp$TOpenSessionRespStandardScheme.read(TOpenSessionResp.java:676) at org.apache.hive.service.cli.thrift.TOpenSessionResp$TOpenSessionRespStandardScheme.read(TOpenSessionResp.java:612) at org.apache.hive.service.cli.thrift.TOpenSessionResp.read(TOpenSessionResp.java:520) at org.apache.hive.service.cli.thrift.TCLIService$OpenSession_result$OpenSession_resultStandardScheme.read(TCLIService.java:2361) at org.apache.hive.service.cli.thrift.TCLIService$OpenSession_result$OpenSession_resultStandardScheme.read(TCLIService.java:2346) at org.apache.hive.service.cli.thrift.TCLIService$OpenSession_result.read(TCLIService.java:2293) at org.apache.thrift.TServiceClient.receiveBase(TServiceClient.java:78) at org.apache.hive.service.cli.thrift.TCLIService$Client.recv_OpenSession(TCLIService.java:160) at org.apache.hive.service.cli.thrift.TCLIService$Client.OpenSession(TCLIService.java:147)

1 ACCEPTED SOLUTION

avatar
Super Guru

what version of hiveserver2 you are running with? it seems that you are trying to connect with old version of thrift client to the newer version of hiveserver2. can you try to check the the libthrift api version of your hive-client vs hive-server.

if there is a mismatch then you are not able to connect with hive-server as it is known issue with hive.

see this

https://issues.apache.org/jira/browse/HIVE-6050

View solution in original post

1 REPLY 1

avatar
Super Guru

what version of hiveserver2 you are running with? it seems that you are trying to connect with old version of thrift client to the newer version of hiveserver2. can you try to check the the libthrift api version of your hive-client vs hive-server.

if there is a mismatch then you are not able to connect with hive-server as it is known issue with hive.

see this

https://issues.apache.org/jira/browse/HIVE-6050