我已经加载了一个文件到我的配置单元表,它是orc文件格式。
当我试图用
hadoop fs -text /apps/hive/warehouse/emp_rcfileformat/000000_0
或者
hive --orcfiledump /apps/hive/warehouse/emp_rcfileformat/000000_0
这不会给我任何结果。。。我用的是Hive0.14
使用文件转储时出错
Exception in thread "main" org.apache.hadoop.hive.ql.io.FileFormatException: Malformed ORC file /apps/hive/warehouse/emp_rcfileformat/000000_0. Invalid postscript.
at org.apache.hadoop.hive.ql.io.orc.ReaderImpl.ensureOrcFooter(ReaderImpl.java:248)
at org.apache.hadoop.hive.ql.io.orc.ReaderImpl.extractMetaInfoFromFooter(ReaderImpl.java:373)
at org.apache.hadoop.hive.ql.io.orc.ReaderImpl.<init>(ReaderImpl.java:314)
at org.apache.hadoop.hive.ql.io.orc.OrcFile.createReader(OrcFile.java:237)
at org.apache.hadoop.hive.ql.io.orc.FileDump.printMetaData(FileDump.java:101)
at org.apache.hadoop.hive.ql.io.orc.FileDump.main(FileDump.java:86)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.apache.hadoop.util.RunJar.run(RunJar.java:221)
at org.apache.hadoop.util.RunJar.main(RunJar.java:136)
2条答案
按热度按时间w80xi6nr1#
orcfile与rcfile不同。请确保您的阅读器与文件格式匹配。
5lhxktic2#
Hive提供
rcfilecat
显示文件内容的工具:$ bin/hive --service rcfilecat /user/hive/warehouse/columntable/000000_0
orc文件转储实用程序:参考:orcfiledumputility