There's a limit for Hadoop counter size. It's 120 by default. I try to use the configuration "mapreduce.job.counters.limit" to change that, but it doesn't work. I've seen the source code. It's like the instance of JobConf in class "org.apache.hadoop.mapred.Counters" is private. Have anybody seen that before? What's your solution? THX :)
相关问题
- Spark on Yarn Container Failure
- enableHiveSupport throws error in java spark code
- spark select and add columns with alias
- Unable to generate jar file for Hadoop
-
hive: cast array
> into map
相关文章
- Java写文件至HDFS失败
- mapreduce count example
- Creating a dictionary for each word in a file and
- Could you give me any clue Why 'Cannot call me
- Is there any limit on number of html elements, tha
- Hive error: parseexception missing EOF
- Exception in thread “main” java.lang.NoClassDefFou
- ClassNotFoundException: org.apache.spark.SparkConf
You can override that property in
mapred-site.xml
on your JT, TT, client nodes but make sure that this will be a system-wide modification:Then restart the mapreduce service on your cluster.
In Hadoop 2, this configuration parameter is called
Setting it on the command line or in your Configuration object isn't enough, though. You need to call the static method
org.apache.hadoop.mapreduce.counters.Limits.init()
in the setup() method of your mapper or reducer to get the setting to take effect.
Tested with 2.6.0 and 2.7.1.
We can customize the limits as command line options only for specific jobs, instead of making change in
mapred-site.xml
.NOTE:
x
andy
are custom values based on your environment/requirement.Just adding this in case anyone else faces the same problem we did: increasing the counters from with MRJob.
To raise the number of counters, add
emr_configurations
to yourmrjob.conf
(or pass it to MRJob as a config parameter):The para is set by config file, while paras below will take effect