AndyTsai 寫:
感謝大大回答,因為不設置,再localhost50030,還是會有一個預設的reduce顯示1,所以才有點疑問,感謝!
因為 mapred-default.xml 預設 reducer 個數是 1 (mapred.reduce.tasks)
所以程式中不做設定的話,會拿 IndentityReducer 當預設的 reducer,個數 1 個。
代碼:
<property>
<name>mapred.reduce.tasks</name>
<value>1</value>
<description>The default number of reduce tasks per job. Typically set to 99%
of the cluster's reduce capacity, so that if a node fails the reduces can
still be executed in a single wave.
Ignored when mapred.job.tracker is "local".
</description>
</property>
- Jazz