Hive启动不报错,当使用show databases…时报:FAILED: SemanticException org.apache.hadoop.hive.ql.metadata.HiveException: java.lang.RuntimeException: Unable to instantiate org.apache.hadoop.hive.ql.metadata.SessionHiveMetaStoreClient异常。
方法1.Hive元数据库未初始化
进入Hive目录Hive/bin,执行命令:
schematool -dbType -initSchema mysql
方法2.metastore服务未启动
执行命令:
nohup /export/servers/hive-1.1.0-cdh5.14.0/bin/hive --service metastore 2>&1 >> /var/log.log &