Support Questions
Find answers, ask questions, and share your expertise

Hive CLI throwing ClientHandlerException on Sandbox 2.4

Super Collaborator

I just downloaded the latest sandbox image (2.4)

I brought up ambari and started all the appropriate services and made everything green.

But something seems to be wrong with Hive.

I tried to open a Hive CLI instance via SSH, and I get the stack trace below whenever I perform any kind of query.

Does anyone know the solution for this?

[root@sandbox parser]# hive

WARNING: Use "yarn jar" to launch YARN applications. Logging initialized using configuration in file:/etc/hive/

hive> show databases;

FAILED: Hive Internal Error: com.sun.jersey.api.client.ClientHandlerException( Connection refused) com.sun.jersey.api.client.ClientHandlerException: Connection refused at com.sun.jersey.client.urlconnection.URLConnectionClientHandler.handle( at com.sun.jersey.api.client.Client.handle( at com.sun.jersey.api.client.WebResource.handle( at com.sun.jersey.api.client.WebResource.access$200( at com.sun.jersey.api.client.WebResource$Builder.method( at org.apache.atlas.AtlasClient.callAPIWithResource( at org.apache.atlas.AtlasClient.callAPIWithResource( at org.apache.atlas.AtlasClient.getType( at org.apache.atlas.hive.bridge.HiveMetaStoreBridge.registerHiveDataModel( at org.apache.atlas.hive.hook.HiveHook.fireAndForget( at at org.apache.hadoop.hive.ql.Driver.execute( at org.apache.hadoop.hive.ql.Driver.runInternal( at at at org.apache.hadoop.hive.cli.CliDriver.processLocalCmd( at org.apache.hadoop.hive.cli.CliDriver.processCmd( at org.apache.hadoop.hive.cli.CliDriver.processLine( at org.apache.hadoop.hive.cli.CliDriver.executeDriver( at at org.apache.hadoop.hive.cli.CliDriver.main( at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke( at sun.reflect.DelegatingMethodAccessorImpl.invoke( at java.lang.reflect.Method.invoke( at at org.apache.hadoop.util.RunJar.main( Caused by: Connection refused at$1$ at$1$ at Method) at at at$1.getHttpURLConnection( at com.sun.jersey.client.urlconnection.URLConnectionClientHandler._invoke( at com.sun.jersey.client.urlconnection.URLConnectionClientHandler.handle( ... 26 more Caused by: Connection refused at Method) at at at at at at at at at<init>( at at at at at at at at at at$1$ ... 33 more



Looks like Atlas server is down. From ambari ui, can you check if atlas is up. If you see it running, take a look at /var/log/atlas/application.log to see if there are any errors.

Super Collaborator

Thanks @Ravi Mutyala,

Atlas appears to be new with 2.4

Is it necessary in 2.4? I'm not familiar with it...


Atlas is a metadata service. By default, its enabled on 2.4 and you can take a look at that has hooks that are triggered from hive.