java.lang.RuntimeException: java.lang.ClassNotFoundException: org.apache.hadoop.examples.WordCount$TokenizerMapper
的问题已解决,解决办法:
remove掉项目的所有jar包(此前这些jar包是eclipse配置hadoop之后,新增mapreduce项目自动引入的)
重新添加hadoop在win7下的安装目录下的所有jia包,是所有哦!!这样问题解决,运行成功。
似乎eclipse自动引入的jar不行!!
感谢所有关注此贴的专家,特别是回复了的专家,所有我的解决办法都列出了,供有需要的新手们参考。着实baidu上类似问题的解决思路可查的不多。 你好,请问你是怎么解决的,我按照你说的重新导入jar包也不行啊,一直报错
14/12/06 10:41:58 WARN mapred.JobClient: No job jar file set.User classes may not be found. See JobConf(Class) or JobConf#setJar(String).
14/12/06 10:41:58 INFO input.FileInputFormat: Total input paths to process : 2
14/12/06 10:41:58 WARN util.NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicable
14/12/06 10:41:58 WARN snappy.LoadSnappy: Snappy native library not loaded
14/12/06 10:42:00 INFO mapred.JobClient: Running job: job_201412062143_0002
14/12/06 10:42:01 INFO mapred.JobClient:map 0% reduce 0%
14/12/06 10:42:11 INFO mapred.JobClient: Task Id : attempt_201412062143_0002_m_000000_0, Status : FAILED
java.lang.RuntimeException: java.lang.ClassNotFoundException: org.apache.hadoop.examples.WordCount$TokenizerMapper
at org.apache.hadoop.conf.Configuration.getClass(Configuration.java:849)
at org.apache.hadoop.mapreduce.JobContext.getMapperClass(JobContext.java:199)
at org.apache.hadoop.mapred.MapTask.runNewMapper(MapTask.java:719)
at org.apache.hadoop.mapred.MapTask.run(MapTask.java:370)
at org.apache.hadoop.mapred.Child$4.run(Child.java:255)
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:1149)
at org.apache.hadoop.mapred.Child.main(Child.java:249)
Caused by: java.lang.ClassNotFoundException: org.apache.hadoop.examples.WordCount$TokenizerMapper
at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:249)
at org.apache.hadoop.conf.Configuration.getClassByName(Configuration.java:802)
at org.apache.hadoop.conf.Configuration.getClass(Configuration.java:847)
... 8 more
14/12/06 10:42:14 WARN mapred.JobClient: Error reading task outputworker3
14/12/06 10:42:14 WARN mapred.JobClient: Error reading task outputworker3
14/12/06 10:42:15 INFO mapred.JobClient: Task Id : attempt_201412062143_0002_m_000001_0, Status : FAILED
java.lang.RuntimeException: java.lang.ClassNotFoundException: org.apache.hadoop.examples.WordCount$TokenizerMapper
at org.apache.hadoop.conf.Configuration.getClass(Configuration.java:849)
at org.apache.hadoop.mapreduce.JobContext.getMapperClass(JobContext.java:199)
at org.apache.hadoop.mapred.MapTask.runNewMapper(MapTask.java:719)
at org.apache.hadoop.mapred.MapTask.run(MapTask.java:370)
at org.apache.hadoop.mapred.Child$4.run(Child.java:255)
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:1149)
at org.apache.hadoop.mapred.Child.main(Child.java:249)
Caused by: java.lang.ClassNotFoundException: org.apache.hadoop.examples.WordCount$TokenizerMapper
at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:249)
at org.apache.hadoop.conf.Configuration.getClassByName(Configuration.java:802)
at org.apache.hadoop.conf.Configuration.getClass(Configuration.java:847)
... 8 more
顶顶顶!!!!!! 14/12/06 10:42:11 INFO mapred.JobClient: Task Id : attempt_201412062143_0002_m_000000_0, Status : FAILED
java.lang.RuntimeException: java.lang.ClassNotFoundException: org.apache.hadoop.examples.WordCount$TokenizerMapper
这个问题解决了吗?我也碰到这样的鬼问题了。。。tmd好烦。
页:
1
[2]