How to set the number of Map & Reduce tasks?

0 votes

I am executing a MapReduce task. I have specified the mapred.map.tasks property to 20 & mapred.reduce.tasks to 0. But still I am getting a different number of mapper & reducer tasks. My command is

hadoop jar Example.jar Example abc.txt Result \ -D mapred.map.tasks = 20 \ -D mapred.reduce.tasks =0

Can anyone help me in understanding what is the problem here & how can I fix this?

Apr 18, 2018 in Big Data Hadoop by nitinrawat895
• 10,730 points
95 views

1 answer to this question.

0 votes

The map tasks created for a job is equal to the number of the of input splits created. For each input split a map job is created. The mapred.map.tasks property hints InputFormat about the map tasks created.

For the reduce tasks you have to remove the extra space after -D.

answered Apr 18, 2018 by Shubham
• 13,310 points

Related Questions In Big Data Hadoop

0 votes
1 answer

Setting the Number of Map tasks and Reduce Tasks not Working

The command that you are running is ...READ MORE

answered May 3, 2018 in Big Data Hadoop by Ashish
• 2,630 points
168 views
+2 votes
1 answer

How to calculate Maximum salary of the employee with the name using the Map Reduce Technique

Please try the below code and it ...READ MORE

answered Jul 25, 2018 in Big Data Hadoop by Neha
• 6,280 points
611 views
0 votes
2 answers

How to set up Map and Reduce Tasks?

Hi, The number of map tasks for a ...READ MORE

answered Aug 5 in Big Data Hadoop by Rashi
89 views
0 votes
1 answer
0 votes
1 answer

Hadoop Mapreduce word count Program

Firstly you need to understand the concept ...READ MORE

answered Mar 16, 2018 in Data Analytics by nitinrawat895
• 10,730 points
3,390 views
0 votes
10 answers

hadoop fs -put command?

put syntax: put <localSrc> <dest> copy syntax: copyFr ...READ MORE

answered Dec 7, 2018 in Big Data Hadoop by Aditya
16,922 views
0 votes
1 answer

Hadoop dfs -ls command?

In your case there is no difference ...READ MORE

answered Mar 16, 2018 in Big Data Hadoop by kurt_cobain
• 9,260 points
1,236 views
0 votes
1 answer
0 votes
11 answers
0 votes
1 answer

How to print the content of a file in console present in HDFS?

Yes, you can use hdfs dfs command ...READ MORE

answered Apr 19, 2018 in Big Data Hadoop by Shubham
• 13,310 points
668 views