通过Cygwin在Windows 7设置中运行Hadoop - PriviledgedActionException为:PC原因:java.io.IOException:无法设置路径的权限:

时间:2013-07-03 09:46:38

标签: hadoop cygwin

我使用Hadoop发行版1.1.2。当我尝试运行示例wordcount例程时,我得到以下错误。

输入命令:

  

' d:/Files/hadoop-1.1.2/hadoop-1.1.2/bin/hadoop' jar' D:/Files/hadoop-1.1.2/hadoop-1.1.2/hadoop-examples-1.1.2.jar' wordcount输入输出

结果:

  

13/07/03 11:02:42 WARN util.NativeCodeLoader:无法为您的平台加载native-hadoop库...使用适用的builtin-java类   13/07/03 11:02:42错误security.UserGroupInformation:PriviledgedActionException as:PC原因:java.io.IOException:无法设置路径权限:\ tmp \ hadoop-PC \ mapred \ staging \ PC119237705.staging to 0700   java.io.IOException:无法将path:\ tmp \ hadoop-PC \ mapred \ staging \ PC119237705.staging的权限设置为0700           在org.apache.hadoop.fs.FileUtil.checkReturnValue(FileUtil.java:689)           在org.apache.hadoop.fs.FileUtil.setPermission(FileUtil.java:662)           at org.apache.hadoop.fs.RawLocalFileSystem.setPermission(RawLocalFileSystem.java:509)           在org.apache.hadoop.fs.RawLocalFileSystem.mkdirs(RawLocalFileSystem.java:344)           在org.apache.hadoop.fs.FilterFileSystem.mkdirs(FilterFileSystem.java:189)           在org.apache.hadoop.mapreduce.JobSubmissionFiles.getStagingDir(JobSubmissionFiles.java:116)           在org.apache.hadoop.mapred.JobClient $ 2.run(JobClient.java:918)           在org.apache.hadoop.mapred.JobClient $ 2.run(JobClient.java:912)           at java.security.AccessController.doPrivileged(Native Method)           在javax.security.auth.Subject.doAs(Subject.java:415)           在org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1149)           在org.apache.hadoop.mapred.JobClient.submitJobInternal(JobClient.java:912)           在org.apache.hadoop.mapreduce.Job.submit(Job.java:500)           在org.apache.hadoop.mapreduce.Job.waitForCompletion(Job.java:530)           在org.apache.hadoop.examples.WordCount.main(WordCount.java:67)           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)           在org.apache.hadoop.util.ProgramDriver $ ProgramDescription.invoke(ProgramDriver.java:68)           在org.apache.hadoop.util.ProgramDriver.driver(ProgramDriver.java:139)           在org.apache.hadoop.examples.ExampleDriver.main(ExampleDriver.java:64)           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)           在org.apache.hadoop.util.RunJar.main(RunJar.java:156)

我有问题找到此错误的特定原因。请帮忙。

1 个答案:

答案 0 :(得分:4)

看起来你已经点击了this。您可能会发现此patch有用。但是,在此之前,您可能想尝试将目录权限更改为755并重新运行该作业。