码迷,mamicode.com
首页 > Windows程序 > 详细

Window7中Eclipse运行MapReduce程序报错的问题

时间:2014-07-29 16:39:32      阅读:482      评论:0      收藏:0      [点我收藏+]

标签:style   blog   http   java   color   strong   文件   io   

按照文档:http://www.micmiu.com/bigdata/hadoop/hadoop2x-eclipse-mapreduce-demo/安装配置好Eclipse后,运行WordCount程序报错:

log4j:WARN No appenders could be found for logger (org.apache.hadoop.metrics2.lib.MutableMetricsFactory).
log4j:WARN Please initialize the log4j system properly.
log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info.
Exception in thread "main" java.lang.NullPointerException
    at java.lang.ProcessBuilder.start(ProcessBuilder.java:1011)
    at org.apache.hadoop.util.Shell.runCommand(Shell.java:404)
    at org.apache.hadoop.util.Shell.run(Shell.java:379)
    at org.apache.hadoop.util.Shell$ShellCommandExecutor.execute(Shell.java:589)
    at org.apache.hadoop.util.Shell.execCommand(Shell.java:678)
    at org.apache.hadoop.util.Shell.execCommand(Shell.java:661)
    at org.apache.hadoop.fs.RawLocalFileSystem.setPermission(RawLocalFileSystem.java:639)
    at org.apache.hadoop.fs.RawLocalFileSystem.mkdirs(RawLocalFileSystem.java:435)
    at org.apache.hadoop.fs.FilterFileSystem.mkdirs(FilterFileSystem.java:277)
    at org.apache.hadoop.mapreduce.JobSubmissionFiles.getStagingDir(JobSubmissionFiles.java:125)
    at org.apache.hadoop.mapreduce.JobSubmitter.submitJobInternal(JobSubmitter.java:344)
    at org.apache.hadoop.mapreduce.Job$10.run(Job.java:1268)
    at org.apache.hadoop.mapreduce.Job$10.run(Job.java:1265)
    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:1491)
    at org.apache.hadoop.mapreduce.Job.submit(Job.java:1265)
    at org.apache.hadoop.mapreduce.Job.waitForCompletion(Job.java:1286)
    at com.telchina.hadoop.WordCount.main(WordCount.java:84)

经过google,发现http://www.uniorder.com/2014/03/31/%E5%9C%A8%20Windows%20%E4%B8%8A%E4%BD%BF%E7%94%A8%20Eclipse%20%E8%BF%9C%E7%A8%8B%E8%B0%83%E8%AF%95%20Hadoop%202.2%20MapReduce%20%E7%A8%8B%E5%BA%8F/中:

下载 Hadoop 2.2 到你的 Windows 机器上(我是 Windows 7)并设置环境变量:HADOOP_HOME=你的Hadoop所在目录,再在Path中加入%HADOOP_HOME%\bin;。此时还没有完成。你需要去下载一些文件覆盖 Hadoop/bin 下的所有文件(戳这里)。

问题解决。



作者:sdjnzqr
出处:http://www.cnblogs.com/sdjnzqr/
版权:本文版权归作者和博客园共有
转载:欢迎转载,但未经作者同意,必须保留此段声明;必须在文章中给出原文连接;否则必究法律责任

Window7中Eclipse运行MapReduce程序报错的问题,布布扣,bubuko.com

Window7中Eclipse运行MapReduce程序报错的问题

标签:style   blog   http   java   color   strong   文件   io   

原文地址:http://www.cnblogs.com/sdjnzqr/p/3875367.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!