相关疑难解决方法(0)

hadoop No FileSystem for scheme:file

我试图运行一个简单的NaiveBayesClassifer使用hadoop,得到这个错误

Exception in thread "main" java.io.IOException: No FileSystem for scheme: file
    at org.apache.hadoop.fs.FileSystem.createFileSystem(FileSystem.java:1375)
    at org.apache.hadoop.fs.FileSystem.access$200(FileSystem.java:66)
    at org.apache.hadoop.fs.FileSystem$Cache.get(FileSystem.java:1390)
    at org.apache.hadoop.fs.FileSystem.get(FileSystem.java:196)
    at org.apache.hadoop.fs.FileSystem.get(FileSystem.java:95)
    at org.apache.hadoop.fs.FileSystem.get(FileSystem.java:180)
    at org.apache.hadoop.fs.Path.getFileSystem(Path.java:175)
    at org.apache.mahout.classifier.naivebayes.NaiveBayesModel.materialize(NaiveBayesModel.java:100)
Run Code Online (Sandbox Code Playgroud)

代码:

    Configuration configuration = new Configuration();
    NaiveBayesModel model = NaiveBayesModel.materialize(new Path(modelPath), configuration);// error in this line..
Run Code Online (Sandbox Code Playgroud)

modelPath指向NaiveBayes.bin文件,配置对象正在打印 -Configuration: core-default.xml, core-site.xml

我认为这是因为罐子,任何想法?

java io hadoop

88
推荐指数
9
解决办法
9万
查看次数

标签 统计

hadoop ×1

io ×1

java ×1