Hadoop集群错误

一、提交MapReduce作业到YARN时报错:org.apache.hadoop.yarn.exceptions.yarnexception: unauthorized request to start container.

  解决办法:同步namenode和datanode的时间。

二、使用Map端Shuffle报错:wrong key class: class org.apache.hadoop.io.NullWritable is not class org.apache.hadoop.io.Text

  解决办法:Map任务本地合并后输出的Key和Value必须一致,在Reduce函数中将输入输出的Key和Value类型设置相同即可,如将reduce<Text, NullWritable, NullWritable, Text> 改为reduce<Text, NullWritable, Text, NullWritable>则解决。

原文地址:https://www.cnblogs.com/mengyao/p/4496465.html