Exceptioninthreadmainjava.lang.IllegalArgumen。。。使⽤fileSystem的delete⽅法⽆法删除⽂件或⽬录
Exception in thread "main" java.lang.IllegalArgumentException: Wrong FS: hdfs://h1:9000/out, expected: file:///
at org.apache.hadoop.fs.FileSystem.checkPath(FileSystem.java:381)
at org.apache.hadoop.fs.RawLocalFileSystem.pathToFile(RawLocalFileSystem.java:55)
at org.apache.hadoop.FileStatus(RawLocalFileSystem.java:393)
at org.apache.hadoop.fs.ChecksumFileSystem.delete(ChecksumFileSystem.java:452)
delete inat mapreduce.WordCountApp.main(WordCountApp.java:36)
由于获取fileSystem对象的时候没有传⼊访问地址导致。
FileSystem fileSystem = (new URI(INPUT_PATH),conf);

版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系QQ:729038198,我们将在24小时内删除。