Exception in thread "main" java.lang.NoSuchMethodError:
org.apache.hadoop.io.compress.SnappyCodec.isNativeCodeLoaded()Z
at org.apache.hadoop.util.NativeLibraryChecker.main(NativeLibraryChecker.java:82)
如果snappy为安装好或安装成功,有可能出现的一种问题如下:
异常堆栈
12345678910111213141516
java.lang.RuntimeException: native snappy library not available: this version of libhadoop was built without snappy support.
at org.apache.hadoop.io.compress.SnappyCodec.checkNativeCodeLoaded(SnappyCodec.java:64)
at org.apache.hadoop.io.compress.SnappyCodec.createDecompressor(SnappyCodec.java:201)
at org.apache.hadoop.io.compress.SnappyCodec.createInputStream(SnappyCodec.java:161)
at org.apache.hadoop.fs.shell.Display$Text.getInputStream(Display.java:150)
at org.apache.hadoop.fs.shell.Display$Cat.processPath(Display.java:98)
at org.apache.hadoop.fs.shell.Command.processPaths(Command.java:306)
at org.apache.hadoop.fs.shell.Command.processPathArgument(Command.java:278)
at org.apache.hadoop.fs.shell.Command.processArgument(Command.java:260)
at org.apache.hadoop.fs.shell.Command.processArguments(Command.java:244)
at org.apache.hadoop.fs.shell.Command.processRawArguments(Command.java:190)
at org.apache.hadoop.fs.shell.Command.run(Command.java:154)
at org.apache.hadoop.fs.FsShell.run(FsShell.java:287)
at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:70)
at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:84)
at org.apache.hadoop.fs.FsShell.main(FsShell.java:340)