Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
是否可以设置每个节点运行的地图任务数。 我正在使用 Hadoop Streaming 来抓取数据,每个节点只需要一个地图任务来避免阻塞。
谢谢,
不管流与否,可以使用mapreduce.tasktracker.map.tasks.maximum参数设置每个节点的最大映射器数。该参数必须在mapred-site.xml节点上的文件中设置,该属性在客户端设置时无效。
mapreduce.tasktracker.map.tasks.maximum
mapred-site.xml
您是否尝试过在 job.xml 中使用以下设置?
mapred.max.maps.per.node=1 mapred.max.reduces.per.node=1
这些默认为 -1,无限制(当然,可用插槽除外)。