日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 人工智能 > ChatGpt >内容正文

ChatGpt

FAILED: Error in metadata: java.lang.RuntimeException: Unable to instantiate org.apache.解决办法

發布時間:2024/4/17 ChatGpt 44 豆豆
生活随笔 收集整理的這篇文章主要介紹了 FAILED: Error in metadata: java.lang.RuntimeException: Unable to instantiate org.apache.解决办法 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

http://blog.csdn.net/lxpbs8851/article/details/11018933

起因是我重裝了mysql數據庫。 安裝之后 把訪問權限都配置好 : GRANT ALL PRIVILEGES ON*.* TO?'hive'@'%'?Identified by 'hive';??
GRANT ALL PRIVILEGES ON*.* TO?'hive'@'localhost'?Identified by 'hive';??
GRANT ALL PRIVILEGES ON*.* TO?'hive'@'127.0.0.1'?Identified by 'hive';??
本機地址: 192.168.103.43? 機器名字:192-168-103-43
flush privileges; 啟動hive 發生下面的錯誤:

hive> show tables;

FAILED: Error in metadata: java.lang.RuntimeException: Unable to instantiate org.apache.hadoop.hive.metastore.HiveMetaStoreClient FAILED: Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.DDLTask

FAILED: Error in metadata: java.lang.RuntimeException: Unable to instantiate org.apache.hadoop.hive.metastore.HiveMetaStoreClientFAILED: Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.DDLTask

?

cd ${HIVE_HOME}/bin

./hive -hiveconf hive.root.logger=DEBUG,console

hive> show tables;

得到如下的錯誤信息(當然 不同的問題所產生的日志是不同的):

Caused by: javax.jdo.JDOFatalDataStoreException: Access denied for user?'hive'@'192-168-103-43'?(using password: YES)
NestedThrowables:
java.sql.SQLException: Access denied for user?'hive'@'192-168-103-43'?(using password: YES)
??????? at org.datanucleus.jdo.NucleusJDOHelper.getJDOExceptionForNucleusException(NucleusJDOHelper.java:298)
??????? at org.datanucleus.jdo.JDOPersistenceManagerFactory.freezeConfiguration(JDOPersistenceManagerFactory.java:601)
??????? at org.datanucleus.jdo.JDOPersistenceManagerFactory.createPersistenceManagerFactory(JDOPersistenceManagerFactory.java:286)
??????? at org.datanucleus.jdo.JDOPersistenceManagerFactory.getPersistenceManagerFactory(JDOPersistenceManagerFactory.java:182)
??????? at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
??????? at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
??????? at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
??????? at java.lang.reflect.Method.invoke(Method.java:597)
??????? at javax.jdo.JDOHelper$16.run(JDOHelper.java:1958)
??????? at java.security.AccessController.doPrivileged(Native Method)
??????? at javax.jdo.JDOHelper.invoke(JDOHelper.java:1953)
??????? at javax.jdo.JDOHelper.invokeGetPersistenceManagerFactoryOnImplementation(JDOHelper.java:1159)
??????? at javax.jdo.JDOHelper.getPersistenceManagerFactory(JDOHelper.java:803)
??????? at javax.jdo.JDOHelper.getPersistenceManagerFactory(JDOHelper.java:698)
??????? at org.apache.hadoop.hive.metastore.ObjectStore.getPMF(ObjectStore.java:262)
??????? at org.apache.hadoop.hive.metastore.ObjectStore.getPersistenceManager(ObjectStore.java:291)
??????? at org.apache.hadoop.hive.metastore.ObjectStore.initialize(ObjectStore.java:224)
??????? at org.apache.hadoop.hive.metastore.ObjectStore.setConf(ObjectStore.java:199)
??????? at org.apache.hadoop.util.ReflectionUtils.setConf(ReflectionUtils.java:62)
??????? at org.apache.hadoop.util.ReflectionUtils.newInstance(ReflectionUtils.java:117)
??????? at org.apache.hadoop.hive.metastore.RetryingRawStore.<init>(RetryingRawStore.java:62)
??????? at org.apache.hadoop.hive.metastore.RetryingRawStore.getProxy(RetryingRawStore.java:71)
??????? at org.apache.hadoop.hive.metastore.HiveMetaStore$HMSHandler.newRawStore(HiveMetaStore.java:413)
??????? at org.apache.hadoop.hive.metastore.HiveMetaStore$HMSHandler.getMS(HiveMetaStore.java:401)
??????? at org.apache.hadoop.hive.metastore.HiveMetaStore$HMSHandler.createDefaultDB(HiveMetaStore.java:439)
??????? at org.apache.hadoop.hive.metastore.HiveMetaStore$HMSHandler.init(HiveMetaStore.java:325)
??????? at org.apache.hadoop.hive.metastore.HiveMetaStore$HMSHandler.<init>(HiveMetaStore.java:285)
??????? at org.apache.hadoop.hive.metastore.RetryingHMSHandler.<init>(RetryingHMSHandler.java:53)
??????? at org.apache.hadoop.hive.metastore.RetryingHMSHandler.getProxy(RetryingHMSHandler.java:58)
??????? at org.apache.hadoop.hive.metastore.HiveMetaStore.newHMSHandler(HiveMetaStore.java:4102)
??????? at org.apache.hadoop.hive.metastore.HiveMetaStoreClient.<init>(HiveMetaStoreClient.java:121)
??????? ... 28 more

?

發現數據庫的權限? HIVE需要的是

'hive'@'192-168-103-43'?這個IP地址

然后試著在mysql中加上權限:

GRANT ALL PRIVILEGES ON*.* TO?'hive'@'192-168-103-43'?Identified by 'hive';?

flush privileges;

?

再次登錄hive

hive> show tables;
OK

?

能正常的查詢表了,希望能幫到有同樣問題的人。



================

我的是com.mysql.jdbc.Driver notfound, 所以需要把mysql的驅動放到hive的lib目錄

總結

以上是生活随笔為你收集整理的FAILED: Error in metadata: java.lang.RuntimeException: Unable to instantiate org.apache.解决办法的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。