Exception in thread "main" java.io.IOException: Failed to set permissions of path
在跑BuildForest的时候,编写了下面的程序:
package test.breiman; import org.apache.mahout.classifier.df.mapreduce.BuildForest;
/**
* BuildForecast测试类
* @author fansy
*/
public class BuildForestFollow {
public static void main(String[] args) throws Exception{
String[] arg=new String[]{
"-d","hdfs://ubuntu:9000/user/breiman/input/glass.data",
"-ds","hdfs://ubuntu:9000/user/breiman/glass.info",
"-sl","5",
"-p",
"-t","10",
"-o","hdfs://ubuntu:9000/user/mahout/output-forest1"
};
BuildForest.main(arg);
}
}
结果一运行,就出现了下面的错误:
13/09/20 17:34:22 INFO mapreduce.BuildForest: Partial Mapred implementation
13/09/20 17:34:22 INFO mapreduce.BuildForest: Building the forest...
13/09/20 17:34:22 WARN util.NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicable
13/09/20 17:34:22 ERROR security.UserGroupInformation: PriviledgedActionException as:Administrator cause:java.io.IOException: Failed to set permissions of path: \tmp\hadoop-Administrator\mapred\staging\Administrator537639001\.staging to 0700
Exception in thread "main" java.io.IOException: Failed to set permissions of path: \tmp\hadoop-Administrator\mapred\staging\Administrator537639001\.staging to 0700
at org.apache.hadoop.fs.FileUtil.checkReturnValue(FileUtil.java:689)
at org.apache.hadoop.fs.FileUtil.setPermission(FileUtil.java:662)
at org.apache.hadoop.fs.RawLocalFileSystem.setPermission(RawLocalFileSystem.java:509)
at org.apache.hadoop.fs.RawLocalFileSystem.mkdirs(RawLocalFileSystem.java:344)
at org.apache.hadoop.fs.FilterFileSystem.mkdirs(FilterFileSystem.java:189)
at org.apache.hadoop.mapreduce.JobSubmissionFiles.getStagingDir(JobSubmissionFiles.java:116)
at org.apache.hadoop.mapred.JobClient$2.run(JobClient.java:856)
at org.apache.hadoop.mapred.JobClient$2.run(JobClient.java:1)
at java.security.AccessController.doPrivileged(Native Method)
at javax.security.auth.Subject.doAs(Subject.java:415)
at org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1121)
at org.apache.hadoop.mapred.JobClient.submitJobInternal(JobClient.java:850)
at org.apache.hadoop.mapreduce.Job.submit(Job.java:500)
at org.apache.hadoop.mapreduce.Job.waitForCompletion(Job.java:530)
at org.apache.mahout.classifier.df.mapreduce.Builder.runJob(Builder.java:255)
at org.apache.mahout.classifier.df.mapreduce.Builder.build(Builder.java:296)
at org.apache.mahout.classifier.df.mapreduce.BuildForest.buildForest(BuildForest.java:229)
at org.apache.mahout.classifier.df.mapreduce.BuildForest.run(BuildForest.java:189)
at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:65)
at org.apache.mahout.classifier.df.mapreduce.BuildForest.main(BuildForest.java:253)
at test.breiman.BuildForestFollow.main(BuildForestFollow.java:18)
上网找,说是要替换hadoop的相关包,才行。但是我之前运行其他的Job都是ok的,所以这个问题还应该是其他,而非是网上的解决方式。之前遇到这个问题的时候解决了一次,但是当时没有记录下来,结果忘记了。晕。。。
这次的解决方式是,看BuildForest的源码,看到里面关于路径的设置是outputPath.getName();同时configuration是按照默认的。这样肯定是不行的,所以就修改相应的代码把outputPath.getName()改为outputPath.toString(),同时把configuration附上我主节点的相关信息,然后就可以了。
Exception in thread "main" java.io.IOException: Failed to set permissions of path的更多相关文章
- windows下eclipse远程连接hadoop错误“Exception in thread"main"java.io.IOException: Call to Master.Hadoop/172.20.145.22:9000 failed ”
在VMware虚拟机下搭建了hadoop集群,ubuntu-12.04,一台master,三台slave.hadoop-0.20.2版本.在 master机器上利用eclipse-3.3连接hadoo ...
- nutch爬取时Exception in thread “main” java.io.IOException: Job failed!
用cygwin运行nutch 1.2爬取提示IOException: $ bin/nutch crawl urls -dir crawl -depth 3 -topN 10 crawl started ...
- 解决方案--java执行cmd命令ProcessBuilder--出错Exception in thread "main" java.io.IOException: Cannot run program "dir d:\": CreateProcess error=2(xjl456852原创)
当我尝试在java中通过ProcessBuilder运行window的cmd命令时出现错误: public static void main(String [] args) throws IOExce ...
- WARN util.NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicable Exception in thread "main" java.io.IOException: No FileSystem for sc F
1.执行脚本程序报如下所示的错误: [hadoop@slaver1 script_hadoop]$ hadoop jar web_click_mr_hive.jar com.bie.hive.mr.C ...
- jmap Exception in thread "main" java.io.IOException: 拒绝访问。
环境: 现有一个独立运行的系统S(有独立的jre,但是没jdk),现想通过jmap导出其内存堆栈信息.于是另外安装一个jdk.可是jdk的版本跟S系统的jre不能对应上.出了很多错误. 总是报错: C ...
- spark运行java-jar:Exception in thread "main" java.io.IOException: No FileSystem for scheme: hdfs
今天碰到的一个 spark问题,困扰好久才解决 首先我的spark集群部署使用的部署包是官方提供的 spark-1.0.2-bin-hadoop2.tgz 部署在hadoop集群上. 在运行java ...
- Exception in thread "main" java.io.IOException: Mkdirs failed to create /var/folders/q0/1wg8sw1x0dg08cmm5m59sy8r0000gn/T/hadoop-unjar6090005653875084137/META-INF/license at org.apache.hadoop.util.Run
在使用hadoop运行jar时出现. 解决方法 zip -d Test.jar LICENSE zip -d Test.jar META-INF/LICENSE 完美解决.
- Exception in thread "main" java.lang.IllegalStateException: Failed to read 问题解决
开发中偶尔遇到这样的问题:Exception in thread "main" java.lang.IllegalStateException: Failed to read .. ...
- Exception in thread "main" java.lang.IllegalStateException: Failed to read Class-Path attribute from manifest of jar file:
表示jar所在位置文件夾中沒有下載好,將目標目錄刪除,重新maven下就好了
随机推荐
- Eclipse总是自动关闭
-Dosgi.requiredJavaVersion=1.5把INI文件中的这一行删除掉,貌似这样以后模拟器也没再出现timeout的问题了,O(∩_∩)O哈哈~
- Valid Anagram 解答
Question Given two strings s and t, write a function to determine if t is an anagram of s. For examp ...
- LeeCode-Pow(x, n)
Implement pow(x, n). double myPow(double x, int n) { ) return 1.0; ) return 1.0/pow(x,-n); ); }
- 如何将ASM中的数据文件复制到操作系统中
环境:Red Hat 5.7 + Oracle 10.2.0.5.0 Rac+ASM 如果你的Oracle数据库系统使用正使用ASM自动存储管理,你可曾想过要窥视一下ASM中的数据文件,ASM是个黑匣 ...
- JAVA Grammar Corrector
1. Integer.MAX_VALUE, Integer.MIN_VALUE 2. int[] res = {1,2} can only be used in the initialization, ...
- Mac神器Iterm2的Shell Integration的用法和注意事项
在iterm2 v3.0版本中有了个新的feature——Shell Integration,其中比较重要的功能就是可以取代传统的“rz”.“sz”(即:向服务器上传.下载文件) 具体的用法可以参见官 ...
- [Python笔记][第二章Python序列-tuple,dict,set]
2016/1/27学习内容 第二章 Python序列-tuple tuple创建的tips a_tuple=('a',),要这样创建,而不是a_tuple=('a'),后者是一个创建了一个字符 tup ...
- 【贪心+中位数】【UVa 11300】 分金币
(解方程建模+中位数求最短累积位移) 分金币(Spreading the Wealth, UVa 11300) 圆桌旁坐着n个人,每人有一定数量的金币,金币总数能被n整除.每个人可以给他左右相邻的人一 ...
- ADO.net基础学习总结(二)
将连接字符串放入配置文件中 1.添加一个“应用程序配置文件:app.config” <?xml version="1.0" encoding="utf-8" ...
- UVA 11214 Guarding the Chessboard
题意: 皇后防御的范围是他所在横.竖.对角线,地图上的#为可以放旗子的地方.问最少放几个皇后能防守所有#. 分析: vis数组开4维,对应行.列.主对角线.副对角线 代码: #include < ...