一步步遵循 Hive apache wiki 时的 Hive 安装问题
按照 Hive apache wiki 上的说明一步步安装 Hive 后,我调用 hive shell 并输入“CREATE TABLE pokes (foo INT, bar STRING);”,然后出现以下错误,还包括日志。
我是 Hive 新手,有什么建议或意见吗?多谢!我通过谷歌网络找到了提出的问题,但没有找到解决方案。
我在 Mac 上使用 Hadoop 单机模式。
蜂巢>创建表 pokes (foo INT, bar STRING); 失败:元数据错误:javax.jdo.JDOFatalInternalException:捕获意外异常。 嵌套Throwables: java.lang.reflect.InitationTargetException 失败:执行错误,从 org.apache.hadoop.hive.ql.exec.DDLTask
日志文件返回代码 1:
Last login: Tue Jun 14 00:27:51 on ttys001 Zhiyong-Xies-MacBook-Pro:~ hadoop$ cat /tmp/*/hive.log 2011-06-14 00:31:54,834 ERROR metastore.HiveMetaStore (HiveMetaStore.java:executeWithRetry(334)) - JDO datastore error. Retrying metastore command after 1000 ms (attempt 1 of 1) 2011-06-14 00:31:56,012 ERROR exec.DDLTask (SessionState.java:printError(374)) - FAILED: Error in metadata: javax.jdo.JDOFatalInternalException: Unexpected exception caught. NestedThrowables: java.lang.reflect.InvocationTargetException org.apache.hadoop.hive.ql.metadata.HiveException: javax.jdo.JDOFatalInternalException: Unexpected exception caught. NestedThrowables: java.lang.reflect.InvocationTargetException at org.apache.hadoop.hive.ql.metadata.Hive.createTable(Hive.java:491) at org.apache.hadoop.hive.ql.exec.DDLTask.createTable(DDLTask.java:3233) at org.apache.hadoop.hive.ql.exec.DDLTask.execute(DDLTask.java:221) at org.apache.hadoop.hive.ql.exec.Task.executeTask(Task.java:132) at org.apache.hadoop.hive.ql.exec.TaskRunner.runSequential(TaskRunner.java:57) at org.apache.hadoop.hive.ql.Driver.launchTask(Driver.java:1238) at org.apache.hadoop.hive.ql.Driver.execute(Driver.java:1050) at org.apache.hadoop.hive.ql.Driver.run(Driver.java:885) at org.apache.hadoop.hive.cli.CliDriver.processCmd(CliDriver.java:224) at org.apache.hadoop.hive.cli.CliDriver.processLine(CliDriver.java:358) at org.apache.hadoop.hive.cli.CliDriver.main(CliDriver.java:593) 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 org.apache.hadoop.util.RunJar.main(RunJar.java:156) Caused by: javax.jdo.JDOFatalInternalException: Unexpected exception caught. NestedThrowables: java.lang.reflect.InvocationTargetException at javax.jdo.JDOHelper.invokeGetPersistenceManagerFactoryOnImplementation(JDOHelper.java:1186) 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:237) at org.apache.hadoop.hive.metastore.ObjectStore.getPersistenceManager(ObjectStore.java:266) at org.apache.hadoop.hive.metastore.ObjectStore.initialize(ObjectStore.java:199) at org.apache.hadoop.hive.metastore.ObjectStore.setConf(ObjectStore.java:174) 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.HiveMetaStore$HMSHandler.getMS(HiveMetaStore.java:369) at org.apache.hadoop.hive.metastore.HiveMetaStore$HMSHandler.executeWithRetry(HiveMetaStore.java:321) at org.apache.hadoop.hive.metastore.HiveMetaStore$HMSHandler.createDefaultDB(HiveMetaStore.java:466) at org.apache.hadoop.hive.metastore.HiveMetaStore$HMSHandler.init(HiveMetaStore.java:240) at org.apache.hadoop.hive.metastore.HiveMetaStore$HMSHandler.(HiveMetaStore.java:203) at org.apache.hadoop.hive.metastore.HiveMetaStoreClient.(HiveMetaStoreClient.java:107) at org.apache.hadoop.hive.ql.metadata.Hive.createMetaStoreClient(Hive.java:2010) at org.apache.hadoop.hive.ql.metadata.Hive.getMSC(Hive.java:2020) at org.apache.hadoop.hive.ql.metadata.Hive.createTable(Hive.java:485) ... 15 more Caused by: java.lang.reflect.InvocationTargetException 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) ... 32 more Caused by: java.lang.NullPointerException at org.datanucleus.plugin.NonManagedPluginRegistry.registerBundle(NonManagedPluginRegistry.java:443) at org.datanucleus.plugin.NonManagedPluginRegistry.registerBundle(NonManagedPluginRegistry.java:355) at org.datanucleus.plugin.NonManagedPluginRegistry.registerExtensions(NonManagedPluginRegistry.java:215) at org.datanucleus.plugin.NonManagedPluginRegistry.registerExtensionPoints(NonManagedPluginRegistry.java:156) at org.datanucleus.plugin.PluginManager.registerExtensionPoints(PluginManager.java:82) at org.datanucleus.OMFContext.(OMFContext.java:156) at org.datanucleus.OMFContext.(OMFContext.java:137) at org.datanucleus.ObjectManagerFactoryImpl.initialiseOMFContext(ObjectManagerFactoryImpl.java:132) at org.datanucleus.jdo.JDOPersistenceManagerFactory.initialiseProperties(JDOPersistenceManagerFactory.java:363) at org.datanucleus.jdo.JDOPersistenceManagerFactory.(JDOPersistenceManagerFactory.java:307) at org.datanucleus.jdo.JDOPersistenceManagerFactory.createPersistenceManagerFactory(JDOPersistenceManagerFactory.java:255) at org.datanucleus.jdo.JDOPersistenceManagerFactory.getPersistenceManagerFactory(JDOPersistenceManagerFactory.java:182) ... 40 more 2011-06-14 00:31:56,014 ERROR ql.Driver (SessionState.java:printError(374)) - FAILED: Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.DDLTask
After installed Hive by the instruction on Hive apache wiki step by step, I invoked hive shell and typed "CREATE TABLE pokes (foo INT, bar STRING);", then it comes following error, log is also included.
I'm new to Hive, any suggestion or comments? Thanks a lot! I found the questions asked over google the web, but did not find solution.
I use single machine mode for Hadoop on Mac.
hive> CREATE TABLE pokes (foo INT, bar STRING);
FAILED: Error in metadata: javax.jdo.JDOFatalInternalException: Unexpected exception caught.
NestedThrowables:
java.lang.reflect.InvocationTargetException
FAILED: Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.DDLTask
log file:
Last login: Tue Jun 14 00:27:51 on ttys001 Zhiyong-Xies-MacBook-Pro:~ hadoop$ cat /tmp/*/hive.log 2011-06-14 00:31:54,834 ERROR metastore.HiveMetaStore (HiveMetaStore.java:executeWithRetry(334)) - JDO datastore error. Retrying metastore command after 1000 ms (attempt 1 of 1) 2011-06-14 00:31:56,012 ERROR exec.DDLTask (SessionState.java:printError(374)) - FAILED: Error in metadata: javax.jdo.JDOFatalInternalException: Unexpected exception caught. NestedThrowables: java.lang.reflect.InvocationTargetException org.apache.hadoop.hive.ql.metadata.HiveException: javax.jdo.JDOFatalInternalException: Unexpected exception caught. NestedThrowables: java.lang.reflect.InvocationTargetException at org.apache.hadoop.hive.ql.metadata.Hive.createTable(Hive.java:491) at org.apache.hadoop.hive.ql.exec.DDLTask.createTable(DDLTask.java:3233) at org.apache.hadoop.hive.ql.exec.DDLTask.execute(DDLTask.java:221) at org.apache.hadoop.hive.ql.exec.Task.executeTask(Task.java:132) at org.apache.hadoop.hive.ql.exec.TaskRunner.runSequential(TaskRunner.java:57) at org.apache.hadoop.hive.ql.Driver.launchTask(Driver.java:1238) at org.apache.hadoop.hive.ql.Driver.execute(Driver.java:1050) at org.apache.hadoop.hive.ql.Driver.run(Driver.java:885) at org.apache.hadoop.hive.cli.CliDriver.processCmd(CliDriver.java:224) at org.apache.hadoop.hive.cli.CliDriver.processLine(CliDriver.java:358) at org.apache.hadoop.hive.cli.CliDriver.main(CliDriver.java:593) 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 org.apache.hadoop.util.RunJar.main(RunJar.java:156) Caused by: javax.jdo.JDOFatalInternalException: Unexpected exception caught. NestedThrowables: java.lang.reflect.InvocationTargetException at javax.jdo.JDOHelper.invokeGetPersistenceManagerFactoryOnImplementation(JDOHelper.java:1186) 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:237) at org.apache.hadoop.hive.metastore.ObjectStore.getPersistenceManager(ObjectStore.java:266) at org.apache.hadoop.hive.metastore.ObjectStore.initialize(ObjectStore.java:199) at org.apache.hadoop.hive.metastore.ObjectStore.setConf(ObjectStore.java:174) 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.HiveMetaStore$HMSHandler.getMS(HiveMetaStore.java:369) at org.apache.hadoop.hive.metastore.HiveMetaStore$HMSHandler.executeWithRetry(HiveMetaStore.java:321) at org.apache.hadoop.hive.metastore.HiveMetaStore$HMSHandler.createDefaultDB(HiveMetaStore.java:466) at org.apache.hadoop.hive.metastore.HiveMetaStore$HMSHandler.init(HiveMetaStore.java:240) at org.apache.hadoop.hive.metastore.HiveMetaStore$HMSHandler.(HiveMetaStore.java:203) at org.apache.hadoop.hive.metastore.HiveMetaStoreClient.(HiveMetaStoreClient.java:107) at org.apache.hadoop.hive.ql.metadata.Hive.createMetaStoreClient(Hive.java:2010) at org.apache.hadoop.hive.ql.metadata.Hive.getMSC(Hive.java:2020) at org.apache.hadoop.hive.ql.metadata.Hive.createTable(Hive.java:485) ... 15 more Caused by: java.lang.reflect.InvocationTargetException 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) ... 32 more Caused by: java.lang.NullPointerException at org.datanucleus.plugin.NonManagedPluginRegistry.registerBundle(NonManagedPluginRegistry.java:443) at org.datanucleus.plugin.NonManagedPluginRegistry.registerBundle(NonManagedPluginRegistry.java:355) at org.datanucleus.plugin.NonManagedPluginRegistry.registerExtensions(NonManagedPluginRegistry.java:215) at org.datanucleus.plugin.NonManagedPluginRegistry.registerExtensionPoints(NonManagedPluginRegistry.java:156) at org.datanucleus.plugin.PluginManager.registerExtensionPoints(PluginManager.java:82) at org.datanucleus.OMFContext.(OMFContext.java:156) at org.datanucleus.OMFContext.(OMFContext.java:137) at org.datanucleus.ObjectManagerFactoryImpl.initialiseOMFContext(ObjectManagerFactoryImpl.java:132) at org.datanucleus.jdo.JDOPersistenceManagerFactory.initialiseProperties(JDOPersistenceManagerFactory.java:363) at org.datanucleus.jdo.JDOPersistenceManagerFactory.(JDOPersistenceManagerFactory.java:307) at org.datanucleus.jdo.JDOPersistenceManagerFactory.createPersistenceManagerFactory(JDOPersistenceManagerFactory.java:255) at org.datanucleus.jdo.JDOPersistenceManagerFactory.getPersistenceManagerFactory(JDOPersistenceManagerFactory.java:182) ... 40 more 2011-06-14 00:31:56,014 ERROR ql.Driver (SessionState.java:printError(374)) - FAILED: Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.DDLTask
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
删除 $HADOOP_HOME /
build 目录就像魅力一样。
http://getsatisfaction.com/cloudera/topics/hive_error_error_in_metadata_javax_jdo_jdofatalinternalexception
Removing the $HADOOP_HOME/build directory worked like a charm.
删除目录 $HADOOP_HOME/build(实际上只是重命名)也适用于 hive-0.9.0 和 hadoop-1.0.4。
Removing the directory $HADOOP_HOME/build (actually just renaming it) also works for hive-0.9.0 and hadoop-1.0.4.