Hadoop - Mapreduce作业无法在Windows中运行(Cygwin)

时间:2013-06-28 06:45:44

标签: hadoop mapreduce

我在windows中安装了cygwin,并在其上配置了hadoop0.20.0,我可以在eclipse中成功运行word count项目,但是当我在hadoop- 中运行wordcount时。。* - example.jar,它会抛出以下错误

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)

会出现什么问题,plz assit

1 个答案:

答案 0 :(得分:0)

你的命令对我来说很好。尝试给出带文件名的输入路径。我希望这能解决你的问题。

bin/hadoop jar hadoop-0.20.0-examples.jar wordcount /user/input/input_file.txt /user/output