报错详情:

WARN mapred.JobClient: No job jar file set.  User classes may not be found. See JobConf(Class) or JobConf#setJar(String).
10/08/16 15:25:49 INFO input.FileInputFormat: Total input paths to process : 4
10/08/16 15:25:50 INFO mapred.JobClient: Running job: job_201008161439_0004
10/08/16 15:25:51 INFO mapred.JobClient:  map 0% reduce 0%
10/08/16 15:26:00 INFO mapred.JobClient: Task Id : attempt_201008161439_0004_m_000000_0, Status : FAILED
java.lang.RuntimeException: java.lang.ClassNotFoundException: org.apache.hadoop.examples.WordCount2$WordCountMapper
at org.apache.hadoop.conf.Configuration.getClass(Configuration.java:808)
at org.apache.hadoop.mapreduce.JobContext.getMapperClass(JobContext.java:157)
at org.apache.hadoop.mapred.MapTask.runNewMapper(MapTask.java:532)
at org.apache.hadoop.mapred.MapTask.run(MapTask.java:305)
at org.apache.hadoop.mapred.Child.main(Child.java:170)
Caused by: java.lang.ClassNotFoundException: org.apache.hadoop.examples.WordCount2$WordCountMapper
at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)

 报错原因:

找不到job任务运行的资源,如map类、reduce类等。

 解决方案:

新增
public class InitMain{
Job job = new Job();
job.setJarByClass(InitMain.class); //只要是Initmain类所在包下的任一个类名都可以,默认为当前 job所在类名。
}

 扩展:

Hadoop之——MapReduce job的几种运行模式

运行一个Hadoop Job所需要指定的属性

MapReduce 中job.setJarByClass()方法的疑惑

Hadoop Job的提交

mapred.JobClient: No job jar file set. User classes may not be found. See JobConf(Class) or JobConf#setJar(String).的更多相关文章

  1. eclipse下提交job时报错mapred.JobClient: No job jar file set. User classes may not be found.

    错误信息: 11/10/14 13:52:07 WARN mapred.JobClient: Use GenericOptionsParser for parsing the arguments. A ...

  2. eclipse 运行 mapreduce程序报错 No job jar file set. User classes may not be found. See JobConf(Class) or JobConf#setJar(String).

    报错信息 17/07/06 17:00:27 WARN mapred.JobClient: Use GenericOptionsParser for parsing the arguments. Ap ...

  3. eclipse 中的 jar file 和 runnable jar file的区别

    转自于:http://blog.csdn.net/lijiecong/article/details/6266234 java最难学的就是角落的东东了,不愧叫做java平台.搜索了一把总算明白了. 直 ...

  4. 现网环境业务不影响,但是tomcat启动一直有error日志,ERROR org.apache.catalina.startup.ContextConfig- Unable to process Jar entry [module-info.class] from Jar [jar:file:/home/iufs/apache-tomcat/webapps/iufs/WEB-INF/lib/asm

    完整的错误日志信息: 2019-03-19 15:30:42,021 [main] INFO org.apache.catalina.core.StandardEngine- Starting Ser ...

  5. An SPI class of type org.apache.lucene.codecs.PostingsFormat with name 'Lucene50' does not exist. You need to add the corresponding JAR file supporting this SPI to your classpath. The current classp

    背景介绍: 当ES中guava库与hive等组件的库冲突时,对Elasticsearch库进行shade,relocate解决库冲突问题. 当使用"org.apache.maven.plug ...

  6. org.apache.jasper.JasperException:Unable to read TLD "META-INF/c-1_0-rt.tld" from JAR file jstl-1.2.jar

    前两天把项目从eclipse EE版搬到MyEclipse中了.配置好jdk,确定build path中没有报错后,在tomcat中运行.结果,报错: org.apache.jasper.Jasper ...

  7. Eclipse------使用Debug As时报错java.lang.IllegalStateException: Failed to read Class-Path attribute from manifest of jar file:/XXX

    报错信息: java.lang.IllegalStateException: Failed to read Class-Path attribute from manifest of jar file ...

  8. Unable to read TLD "META-INF/c.tld" from JAR file

      Unable to read TLD "META-INF/c.tld" from JAR file CreationTime--2018年7月18日17点46分 Author: ...

  9. Failed to read Class-Path attribute from manifest of jar file:/XXX问题

    java.lang.IllegalStateException: Failed to read Class-Path attribute from manifest of jar file:/XXX ...

随机推荐

  1. 论Spark高手是怎样炼成的

    SPARK J大数据的处理怎么能变快一点,答案是请用spark,因为它是基于内存的,可以有效减少数据的落地次数.Spark性能超过Hadoop百倍,从多迭代批量处理出发,兼收并蓄数据仓库.流处理和图计 ...

  2. cors实现跨域(.net和jquery)

    本文引用自:http://blog.csdn.net/xuwei_xuwei/article/details/29845865 客户端 一个jquery cors请求例子: $.ajax({     ...

  3. codeforces 820A. Mister B and Book Reading 解题报告

    题目链接:http://codeforces.com/problemset/problem/820/A 坑爹题目,坑爹题目,坑爹题目....汗 = =!  后台还110个 test 有个地方需要注意下 ...

  4. Appium 自动化测试(5)-- Appium详细介绍:Appium 手机自动化测试_TesterHome公开版pdf

  5. Build_Release.bat

    Build_Release.bat @echo off pushd "%~dp0" set tag=Release set PATH="C:\Program Files ...

  6. 关于inline函数

    本文为大便一箩筐的原创内容,转载请注明出处,谢谢:http://www.cnblogs.com/dbylk/p/4975474.html 今天我在优化公司项目代码的过程中,借助了Intel的VTune ...

  7. c# unicode 编码 中文转换 已测试(转)

    中文传参时因为编码不同经常凌乱风中,故传前编成unicode码来过度是一个不错的解决方法 /// <summary> /// 中文转unicode        /// </summ ...

  8. laravel发送邮件

    这里已163为例: 1..env文件配置和mail.php配置(默认使用.env) MAIL_DRIVER=smtp MAIL_HOST=smtp.163.com MAIL_PORT=465 MAIL ...

  9. cannot be read or is not a valid ZIP file

    在eclipse下创建 maven 项目,运行 flowable 6.1.2 配置maven之后,下载相应的依赖库. 发现报错: Archive for required library: '/Use ...

  10. 高性能高并发服务器架构设计探究——以flamigo服务器代码为例

    这篇文章我们将介绍服务器的开发,并从多个方面探究如何开发一款高性能高并发的服务器程序. 所谓高性能就是服务器能流畅地处理各个客户端的连接并尽量低延迟地应答客户端的请求:所谓高并发,指的是服务器可以同时 ...