Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

Hive server Beeline not working

Highlighted

Hive server Beeline not working

Explorer

Hi Team,

Iam unable to get output for show databases; from beeline. after i restart hinveserver2 service its working after some times. again same issue.. Can someone help me

7 REPLIES 7
Highlighted

Re: Hive server Beeline not working

Rising Star

@suresh krish Please share the output error, if any. Or look under /var/log/hive log files for relevant issues

Highlighted

Re: Hive server Beeline not working

Explorer

2016-04-27 13:38:27,727 WARN thrift.ThriftCLIService (ThriftCLIService.java:ExecuteStatement(492)) - Error executing statement:

org.apache.hive.service.cli.HiveSQLException: Error while processing statement: hive configuration hive.supports.subdirectories does not exists.

at org.apache.hive.service.cli.operation.Operation.toSQLException(Operation.java:315)

at org.apache.hive.service.cli.operation.HiveCommandOperation.runInternal(HiveCommandOperation.java:108)

at org.apache.hive.service.cli.operation.Operation.run(Operation.java:257)

at org.apache.hive.service.cli.session.HiveSessionImpl.executeStatementInternal(HiveSessionImpl.java:388)

at org.apache.hive.service.cli.session.HiveSessionImpl.executeStatement(HiveSessionImpl.java:369)

at org.apache.hive.service.cli.CLIService.executeStatement(CLIService.java:261)

at org.apache.hive.service.cli.thrift.ThriftCLIService.ExecuteStatement(ThriftCLIService.java:486)

at org.apache.hive.service.cli.thrift.TCLIService$Processor$ExecuteStatement.getResult(TCLIService.java:1313)

at org.apache.hive.service.cli.thrift.TCLIService$Processor$ExecuteStatement.getResult(TCLIService.java:1298)

at org.apache.thrift.ProcessFunction.process(ProcessFunction.java:39)

at org.apache.thrift.TBaseProcessor.process(TBaseProcessor.java:39)

at org.apache.hadoop.hive.thrift.HadoopThriftAuthBridge$Server$TUGIAssumingProcessor.process(HadoopThriftAuthBridge.java:692)

at org.apache.thrift.server.TThreadPoolServer$WorkerProcess.run(TThreadPoolServer.java:285)

at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)

at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)

at java.lang.Thread.run(Thread.java:745)

2016-04-27 13:38:27,746 WARN thrift.ThriftCLIService (ThriftCLIService.java:CloseOperation(647)) - Error closing operation:

org.apache.hive.service.cli.HiveSQLException: Invalid OperationHandle: OperationHandle [opType=EXECUTE_STATEMENT, getHandleIdentifier()=16c19444-bd59-462b-8a75-7973d7c991ea]

at org.apache.hive.service.cli.operation.OperationManager.getOperation(OperationManager.java:152)

at org.apache.hive.service.cli.CLIService.closeOperation(CLIService.java:424)

at org.apache.hive.service.cli.thrift.ThriftCLIService.CloseOperation(ThriftCLIService.java:644)

at org.apache.hive.service.cli.thrift.TCLIService$Processor$CloseOperation.getResult(TCLIService.java:1513)

at org.apache.hive.service.cli.thrift.TCLIService$Processor$CloseOperation.getResult(TCLIService.java:1498)

at org.apache.thrift.ProcessFunction.process(ProcessFunction.java:39)

at org.apache.thrift.TBaseProcessor.process(TBaseProcessor.java:39)

at org.apache.hadoop.hive.thrift.HadoopThriftAuthBridge$Server$TUGIAssumingProcessor.process(HadoopThriftAuthBridge.java:692)

at org.apache.thrift.server.TThreadPoolServer$WorkerProcess.run(TThreadPoolServer.java:285)

at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)

at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)

at java.lang.Thread.run(Thread.java:745)

2016-04-27 13:38:27,773 INFO operation.Operation (HiveCommandOperation.java:setupSessionIO(69)) - Putting temp output to file /tmp/hive/9c21d97b-324b-4973-8ecb-75cdeea923844542617662636007338.pipeout

2016-04-27 13:38:27,773 WARN thrift.ThriftCLIService (ThriftCLIService.java:ExecuteStatement(492)) - Error executing statement:

org.apache.hive.service.cli.HiveSQLException: Error while processing statement: Cannot modify mapred.input.dir.recursive at runtime. It is not in list of params that are allowed to be modified at runtime

at org.apache.hive.service.cli.operation.Operation.toSQLException(Operation.java:315)

at org.apache.hive.service.cli.operation.HiveCommandOperation.runInternal(HiveCommandOperation.java:108)

at org.apache.hive.service.cli.operation.Operation.run(Operation.java:257)

at org.apache.hive.service.cli.session.HiveSessionImpl.executeStatementInternal(HiveSessionImpl.java:388)

at org.apache.hive.service.cli.session.HiveSessionImpl.executeStatement(HiveSessionImpl.java:369)

at org.apache.hive.service.cli.CLIService.executeStatement(CLIService.java:261)

at org.apache.hive.service.cli.thrift.ThriftCLIService.ExecuteStatement(ThriftCLIService.java:486)

at org.apache.hive.service.cli.thrift.TCLIService$Processor$ExecuteStatement.getResult(TCLIService.java:1313)

at org.apache.hive.service.cli.thrift.TCLIService$Processor$ExecuteStatement.getResult(TCLIService.java:1298)

at org.apache.thrift.ProcessFunction.process(ProcessFunction.java:39)

at org.apache.thrift.TBaseProcessor.process(TBaseProcessor.java:39)

at org.apache.hadoop.hive.thrift.HadoopThriftAuthBridge$Server$TUGIAssumingProcessor.process(HadoopThriftAuthBridge.java:692)

at org.apache.thrift.server.TThreadPoolServer$WorkerProcess.run(TThreadPoolServer.java:285)

at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)

at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)

at java.lang.Thread.run(Thread.java:745)

2016-04-27 13:38:27,791 WARN thrift.ThriftCLIService (ThriftCLIService.java:CloseOperation(647)) - Error closing operation:

org.apache.hive.service.cli.HiveSQLException: Invalid OperationHandle: OperationHandle [opType=EXECUTE_STATEMENT, getHandleIdentifier()=16c19444-bd59-462b-8a75-7973d7c991ea]

at org.apache.hive.service.cli.operation.OperationManager.getOperation(OperationManager.java:152)

at org.apache.hive.service.cli.CLIService.closeOperation(CLIService.java:424)

at org.apache.hive.service.cli.thrift.ThriftCLIService.CloseOperation(ThriftCLIService.java:644)

at org.apache.hive.service.cli.thrift.TCLIService$Processor$CloseOperation.getResult(TCLIService.java:1513)

at org.apache.hive.service.cli.thrift.TCLIService$Processor$CloseOperation.getResult(TCLIService.java:1498)

at org.apache.thrift.ProcessFunction.process(ProcessFunction.java:39)

at org.apache.thrift.TBaseProcessor.process(TBaseProcessor.java:39)

at org.apache.hadoop.hive.thrift.HadoopThriftAuthBridge$Server$TUGIAssumingProcessor.process(HadoopThriftAuthBridge.java:692)

at org.apache.thrift.server.TThreadPoolServer$WorkerProcess.run(TThreadPoolServer.java:285)

at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)

at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)

at java.lang.Thread.run(Thread.java:745)

2016-04-27 13:38:27,810 INFO operation.Operation (HiveCommandOperation.java:setupSessionIO(69)) - Putting temp output to file /tmp/hive/9c21d97b-324b-4973-8ecb-75cdeea923844542617662636007338.pipeout

2016-04-27 13:38:29,466 INFO thrift.ThriftCLIService (ThriftCLIService.java:OpenSession(294)) - Client protocol version: HIVE

Highlighted

Re: Hive server Beeline not working

Cloudera Employee

You can try the following:

SET mapred.input.dir.recursive=true

Highlighted

Re: Hive server Beeline not working

Rising Star

@suresh krish

Your log points to the below error. Can you check the parameter hive.mapred.supports.subdirectories in hive?

org.apache.hive.service.cli.HiveSQLException: Error while processing statement: hive configuration hive.supports.subdirectories does not exists.
Highlighted

Re: Hive server Beeline not working

Explorer

Yogesh prabu,

I dont have such parameter in my cluster hive.mapred.supports.subdirectories. Please find the actual scenario that i faced.

""" Hive thrift service was not responding for the user query, it was in a hung state when user submit a query using beeline. It was working fine after we restart Hiveserver2 service through Ambari, but after some times it got hung again."""

My Question:

1). Thrift server will get HUNG when i have huge HIVE jobs ?

2). Is their any option to increase the Thrift server jdbc connectivity ?

3) currently 512MB is my Hiveserver 2 Heap size , But i run 10 jobs daily average.. Will this heap size could be the issue ?

Please provide some solution.

Error:

Error:

org.apache.thrift.transport.TTransportException (state=08S01,code=0)

2016-04-27 13:40:50,879 WARN thrift.ThriftCLIService (ThriftCLIService.java:CloseOperation(647)) - Error closing operation:org.apache.hive.service.cli.HiveSQLException: Invalid OperationHandle: OperationHandle [opType=GET_TABLES, getHandleIdentifier()=37fbaa3c-8421-498a-a707-6b98e8bb1dae]

2016-04-27 13:38:27,791 WARN thrift.ThriftCLIService (ThriftCLIService.java:CloseOperation(647)) - Error closing operation:org.apache.hive.service.cli.HiveSQLException: Invalid OperationHandle: OperationHandle [opType=EXECUTE_STATEMENT, getHandleIdentifier()=16c19444-bd59-462b-8a75-7973d7c991ea]

regards

suresh bk

Highlighted

Re: Hive server Beeline not working

Rising Star

As you mentioned after restart it is working fine, Also 512 MB is low for HS2, try with 2GB. But any error in HS2 should tell more.

Highlighted

Re: Hive server Beeline not working

Explorer

Error:

org.apache.thrift.transport.TTransportException (state=08S01,code=0)

2016-04-27 13:40:50,879 WARN thrift.ThriftCLIService (ThriftCLIService.java:CloseOperation(647)) - Error closing operation:org.apache.hive.service.cli.HiveSQLException: Invalid OperationHandle: OperationHandle [opType=GET_TABLES, getHandleIdentifier()=37fbaa3c-8421-498a-a707-6b98e8bb1dae]

2016-04-27 13:38:27,791 WARN thrift.ThriftCLIService (ThriftCLIService.java:CloseOperation(647)) - Error closing operation:org.apache.hive.service.cli.HiveSQLException: Invalid OperationHandle: OperationHandle [opType=EXECUTE_STATEMENT, getHandleIdentifier()=16c19444-bd59-462b-8a75-7973d7c991ea]

Don't have an account?
Coming from Hortonworks? Activate your account here