Hadoop-Mapreduce作业无法在Windows中运行(Cygwin)
我已经在windows中安装了cygwin,并在其上配置了hadoop 0.20.0,我可以在eclipse中成功运行word count项目,但是当我在hadoop-…*-example.jar中运行word count时,它会抛出以下错误Hadoop-Mapreduce作业无法在Windows中运行(Cygwin),hadoop,mapreduce,Hadoop,Mapreduce,我已经在windows中安装了cygwin,并在其上配置了hadoop 0.20.0,我可以在eclipse中成功运行word count项目,但是当我在hadoop-…*-example.jar中运行word count时,它会抛出以下错误 3/06/28 07:32:51 INFO input.FileInputFormat: Total input paths to process : 1 13/06/28 07:32:52 INFO mapred.JobClient: Running j
3/06/28 07:32:51 INFO input.FileInputFormat: Total input paths to process : 1
13/06/28 07:32:52 INFO mapred.JobClient: Running job: job_201306280622_0002
13/06/28 07:32:53 INFO mapred.JobClient: map 0% reduce 0%
13/06/28 07:32:57 INFO mapred.JobClient: Task Id : attempt_201306280622_0002_m_000002_0, Status : FAILED
Error initializing attempt_201306280622_0002_m_000002_0:
org.apache.hadoop.util.Shell$ExitCodeException: //job.jar: invalid mode: `jar'
Try `//job.jar --help' for more information.
at org.apache.hadoop.util.Shell.runCommand(Shell.java:195)
at org.apache.hadoop.util.Shell.run(Shell.java:134)
at org.apache.hadoop.util.Shell$ShellCommandExecutor.execute(Shell.java: 286)
有什么问题吗,我看你的命令不错。尝试用文件名指定输入路径。我希望这能解决你的问题
bin/hadoop jar hadoop-0.20.0-examples.jar wordcount /user/input/input_file.txt /user/output
运行jar的命令是什么?@twid,bin/hadoop-jar-hadoop-0.20.0-examples.jar wordcount/user/input/user/output但它的视图不正确,因为如果我们需要处理一堆文件意味着,提到每个文件名是一件大事。