On 7/18/14, 4:44 AM, Bala Krishna Gangisetty wrote:
Trying to use Tez through HiveSever2 client (beeline). But I was not
successful (pasted error message below). However Tez jobs can be run
successfully through Hive but not through HiveServer2 client. Is there any
specific configuration required for HiveServer2 in the context of Tez? Most
likely, the issue is because of not finding Tez jars in the HiveServer2
classpath. Appreciate any pointer to the HiverServer2 and Tez
configuration.
https://github.com/t3rmin4t0r/tez-autobuild/blob/cb5e946c65bc273aeffacc91cba83d6a2e919a1e/Makefile#L117
Those two lines describe how to setup the class-path via hive-config.sh
(for HS2 & cli at the same time).
When adding classpaths do not forget the directory with tez-site.xml in
it as well as the jar directories.
After doing that, restart HS2 and you can use beeline.
FYI, in this case beeline (or any JDBC/ODBC app) does not need tez in
its classpath, only the server installs require the classpath changes.
Cheers,
Gopal
Error log:
2014-07-17 23:39:05,353 WARN thrift.ThriftCLIService
(ThriftCLIService.java:ExecuteStatement(364)) - Error executing statement:
java.lang.RuntimeException: java.lang.NoClassDefFoundError:
org/apache/tez/dag/api/SessionNotRunning
at
org.apache.hive.service.cli.session.HiveSessionProxy.invoke(HiveSessionProxy.java:84)
at
org.apache.hive.service.cli.session.HiveSessionProxy.access$000(HiveSessionProxy.java:37)
at
org.apache.hive.service.cli.session.HiveSessionProxy$1.run(HiveSessionProxy.java:64)
at java.security.AccessController.doPrivileged(Native Method)
at javax.security.auth.Subject.doAs(Subject.java:415)
at
org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1491)
at
org.apache.hadoop.hive.shims.HadoopShimsSecure.doAs(HadoopShimsSecure.java:500)
at
org.apache.hive.service.cli.session.HiveSessionProxy.invoke(HiveSessionProxy.java:60)
at com.sun.proxy.$Proxy15.executeStatementAsync(Unknown Source)
at
org.apache.hive.service.cli.CLIService.executeStatementAsync(CLIService.java:234)
at
org.apache.hive.service.cli.thrift.ThriftCLIService.ExecuteStatement(ThriftCLIService.java:358)
at
org.apache.hive.service.cli.thrift.TCLIService$Processor$ExecuteStatement.getResult(TCLIService.java:1373)
at
org.apache.hive.service.cli.thrift.TCLIService$Processor$ExecuteStatement.getResult(TCLIService.java:1358)
at org.apache.thrift.ProcessFunction.process(ProcessFunction.java:39)
at org.apache.thrift.TBaseProcessor.process(TBaseProcessor.java:39)
at
org.apache.hive.service.auth.TSetIpAddressProcessor.process(TSetIpAddressProcessor.java:55)
at
org.apache.thrift.server.TThreadPoolServer$WorkerProcess.run(TThreadPoolServer.java:206)
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:744)