m*****k 发帖数: 731 | 1 我在试http://hadoop.apache.org/common/docs/r0.20.2/quickstart.html
我用的是win7 和 cygwin,
Standalone Operation
By default, Hadoop is configured to run in a non-distributed mode, as a
single Java process. This is useful for debugging.
The following example copies the unpacked conf directory to use as input and
then finds and displays every match of the given regular expression. Output
is written to the given output directory.
$ mkdir input
$ cp conf/*.xml input
在这一步
$ bin/hadoop jar hadoop-*-examples.jar grep input output 'dfs[a-z.]+'
总是出错,
看上去是不能更改permission, 实际上.staging根本就没创建出来,但我可以 mkdir -
p /tmp/hadoop-mywinusername/mapred/staging/mywinusername1444391482/.staging
, mywinusername1444391482 是temp folder, 每次都不一样,在windows explorer中
也可在/tmp/hadoop-mywinusername创建folder,不知道为何hadoop运行时不行,求高手
指点,谢谢啦!
------------cygwin console dispaly------------------------------
mywinusername@my-localhost /cygdrive/c/hadoop-0.20.203.0
$ bin/hadoop jar hadoop-examples-0.20.203.0.jar grep input output 'dfs[a-z.]
+'
java.io.IOException: Failed to set permissions of path: file:/tmp/hadoop-
mywinusername/mapred/staging/mywinusername1444391482/.staging to 0700
at org.apache.hadoop.fs.RawLocalFileSystem.checkReturnValue(
RawLocalFileSystem.java:525)
at org.apache.hadoop.fs.RawLocalFileSystem.setPermission(
RawLocalFileSystem.java:499)
at org.apache.hadoop.fs.RawLocalFileSystem.mkdirs(RawLocalFileSystem
.java:318)
at org.apache.hadoop.fs.FilterFileSystem.mkdirs(FilterFileSystem.
java:183)
at org.apache.hadoop.mapreduce.JobSubmissionFiles.getStagingDir(
JobSubmissionFiles.java:116)
at org.apache.hadoop.mapred.JobClient$2.run(JobClient.java:797)
at org.apache.hadoop.mapred.JobClient$2.run(JobClient.java:791)
at java.security.AccessController.doPrivileged(Native Method)
at javax.security.auth.Subject.doAs(Subject.java:396)
at org.apache.hadoop.security.UserGroupInformation.doAs(
UserGroupInformation.java:1059)
at org.apache.hadoop.mapred.JobClient.submitJobInternal(JobClient.
java:791)
at org.apache.hadoop.mapred.JobClient.submitJob(JobClient.java:765)
at org.apache.hadoop.mapred.JobClient.runJob(JobClient.java:1200)
at org.apache.hadoop.examples.Grep.run(Grep.java:69)
at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:65)
at org.apache.hadoop.examples.Grep.main(Grep.java:93)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(
NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(
DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.apache.hadoop.util.ProgramDriver$ProgramDescription.invoke(
ProgramDriver.java:68)
at org.apache.hadoop.util.ProgramDriver.driver(ProgramDriver.java:
139)
at org.apache.hadoop.examples.ExampleDriver.main(ExampleDriver.java:
64)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(
NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(
DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.apache.hadoop.util.RunJar.main(RunJar.java:156) |
m*****k 发帖数: 731 | |
r*******k 发帖数: 44 | 3 很少有人在cygwin 上跑hadoop,所以没人测试,所以就别浪费时间了。
请试试hadoop 1.0.
有问题应该发信到 official user mail list. |
m*****k 发帖数: 731 | 4 我在试http://hadoop.apache.org/common/docs/r0.20.2/quickstart.html
我用的是win7 和 cygwin,
Standalone Operation
By default, Hadoop is configured to run in a non-distributed mode, as a
single Java process. This is useful for debugging.
The following example copies the unpacked conf directory to use as input and
then finds and displays every match of the given regular expression. Output
is written to the given output directory.
$ mkdir input
$ cp conf/*.xml input
在这一步
$ bin/hadoop jar hadoop-*-examples.jar grep input output 'dfs[a-z.]+'
总是出错,
看上去是不能更改permission, 实际上.staging根本就没创建出来,但我可以 mkdir -
p /tmp/hadoop-mywinusername/mapred/staging/mywinusername1444391482/.staging
, mywinusername1444391482 是temp folder, 每次都不一样,在windows explorer中
也可在/tmp/hadoop-mywinusername创建folder,不知道为何hadoop运行时不行,求高手
指点,谢谢啦!
------------cygwin console dispaly------------------------------
mywinusername@my-localhost /cygdrive/c/hadoop-0.20.203.0
$ bin/hadoop jar hadoop-examples-0.20.203.0.jar grep input output 'dfs[a-z.]
+'
java.io.IOException: Failed to set permissions of path: file:/tmp/hadoop-
mywinusername/mapred/staging/mywinusername1444391482/.staging to 0700
at org.apache.hadoop.fs.RawLocalFileSystem.checkReturnValue(
RawLocalFileSystem.java:525)
at org.apache.hadoop.fs.RawLocalFileSystem.setPermission(
RawLocalFileSystem.java:499)
at org.apache.hadoop.fs.RawLocalFileSystem.mkdirs(RawLocalFileSystem
.java:318)
at org.apache.hadoop.fs.FilterFileSystem.mkdirs(FilterFileSystem.
java:183)
at org.apache.hadoop.mapreduce.JobSubmissionFiles.getStagingDir(
JobSubmissionFiles.java:116)
at org.apache.hadoop.mapred.JobClient$2.run(JobClient.java:797)
at org.apache.hadoop.mapred.JobClient$2.run(JobClient.java:791)
at java.security.AccessController.doPrivileged(Native Method)
at javax.security.auth.Subject.doAs(Subject.java:396)
at org.apache.hadoop.security.UserGroupInformation.doAs(
UserGroupInformation.java:1059)
at org.apache.hadoop.mapred.JobClient.submitJobInternal(JobClient.
java:791)
at org.apache.hadoop.mapred.JobClient.submitJob(JobClient.java:765)
at org.apache.hadoop.mapred.JobClient.runJob(JobClient.java:1200)
at org.apache.hadoop.examples.Grep.run(Grep.java:69)
at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:65)
at org.apache.hadoop.examples.Grep.main(Grep.java:93)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(
NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(
DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.apache.hadoop.util.ProgramDriver$ProgramDescription.invoke(
ProgramDriver.java:68)
at org.apache.hadoop.util.ProgramDriver.driver(ProgramDriver.java:
139)
at org.apache.hadoop.examples.ExampleDriver.main(ExampleDriver.java:
64)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(
NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(
DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.apache.hadoop.util.RunJar.main(RunJar.java:156) |
m*****k 发帖数: 731 | |
r*******k 发帖数: 44 | 6 很少有人在cygwin 上跑hadoop,所以没人测试,所以就别浪费时间了。
请试试hadoop 1.0.
有问题应该发信到 official user mail list. |
S****h 发帖数: 558 | 7 I run local mode using cygwin on windows with 0.20.2 with no problem. Make
sure it is set to the local mode. |