hdinsight.github.io

Issue

Unable to connect through beeline. Unable to connect through hive view.

Investigation Steps

  1. First log into Ambari UI. Check if severice HIVESERVER2 INTERACTIVE is up.
  2. If it is not “running” please check is it because the cluster is in safemode.
     $ hdfs dfsadmin -D "fs.default.name=hdfs://mycluster/" -safemode get
    

    If it is showing “ON” we know the safemode is causing this trouble.

There could be different reasons why the cluster is in safemode. Most commom reason is a scale down event.

Mitigation

  1. Forcefully bring the cluster out from safemode.
    $ hdfs dfsadmin -D "fs.default.name=hdfs://mycluster/" -safemode leave
    
  2. Check again if the cluster is out from safemode now.
    $ hdfs dfsadmin -D "fs.default.name=hdfs://mycluster/" -safemode get
    
  3. Once cluster is out from safemode, go to Ambari and check the services in “Hive”, make sure Hiveserver2Interactive is running. If not, start the service.
  4. Now you should be able to use hive view on Ambari.