You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-user@hadoop.apache.org by Jason Yang <li...@gmail.com> on 2012/09/26 07:40:51 UTC
How to get the number of node in cluster?
Hi, all
As I have to run my MapReduce program on clusters of different size, and I
would like the reducer number adapt to (0.95 * NodeNo. *
mapred.tasktracker.reduce.tasks.maximum) automatically, so I was wondering
how to get get the number of node in cluster in a MapReduce Job?
--
YANG, Lin
Re: How to get the number of node in cluster?
Posted by Jason Yang <li...@gmail.com>.
All right, Thanks
2012/9/26 George Datskos <ge...@jp.fujitsu.com>
> Hey Jason,
>
> This should return the number of active tasktrackers in the cluster:
> int numNodes = new JobClient(conf).getClusterStatus().getTaskTrackers()
>
>
>
> Hi, all
>
> As I have to run my MapReduce program on clusters of different size, and
> I would like the reducer number adapt to (0.95 * NodeNo. *
> mapred.tasktracker.reduce.tasks.maximum) automatically, so I was wondering
> how to get get the number of node in cluster in a MapReduce Job?
>
> --
> YANG, Lin
>
>
>
--
YANG, Lin
Re: How to get the number of node in cluster?
Posted by Jason Yang <li...@gmail.com>.
All right, Thanks
2012/9/26 George Datskos <ge...@jp.fujitsu.com>
> Hey Jason,
>
> This should return the number of active tasktrackers in the cluster:
> int numNodes = new JobClient(conf).getClusterStatus().getTaskTrackers()
>
>
>
> Hi, all
>
> As I have to run my MapReduce program on clusters of different size, and
> I would like the reducer number adapt to (0.95 * NodeNo. *
> mapred.tasktracker.reduce.tasks.maximum) automatically, so I was wondering
> how to get get the number of node in cluster in a MapReduce Job?
>
> --
> YANG, Lin
>
>
>
--
YANG, Lin
Re: How to get the number of node in cluster?
Posted by Jason Yang <li...@gmail.com>.
All right, Thanks
2012/9/26 George Datskos <ge...@jp.fujitsu.com>
> Hey Jason,
>
> This should return the number of active tasktrackers in the cluster:
> int numNodes = new JobClient(conf).getClusterStatus().getTaskTrackers()
>
>
>
> Hi, all
>
> As I have to run my MapReduce program on clusters of different size, and
> I would like the reducer number adapt to (0.95 * NodeNo. *
> mapred.tasktracker.reduce.tasks.maximum) automatically, so I was wondering
> how to get get the number of node in cluster in a MapReduce Job?
>
> --
> YANG, Lin
>
>
>
--
YANG, Lin
Re: How to get the number of node in cluster?
Posted by Jason Yang <li...@gmail.com>.
All right, Thanks
2012/9/26 George Datskos <ge...@jp.fujitsu.com>
> Hey Jason,
>
> This should return the number of active tasktrackers in the cluster:
> int numNodes = new JobClient(conf).getClusterStatus().getTaskTrackers()
>
>
>
> Hi, all
>
> As I have to run my MapReduce program on clusters of different size, and
> I would like the reducer number adapt to (0.95 * NodeNo. *
> mapred.tasktracker.reduce.tasks.maximum) automatically, so I was wondering
> how to get get the number of node in cluster in a MapReduce Job?
>
> --
> YANG, Lin
>
>
>
--
YANG, Lin
Re: How to get the number of node in cluster?
Posted by George Datskos <ge...@jp.fujitsu.com>.
Hey Jason,
This should return the number of active tasktrackers in the cluster:
int numNodes = new JobClient(conf).getClusterStatus().getTaskTrackers()
> Hi, all
>
> As I have to run my MapReduce program on clusters of different size,
> and I would like the reducer number adapt to (0.95 * NodeNo. *
> mapred.tasktracker.reduce.tasks.maximum) automatically, so I was
> wondering how to get get the number of node in cluster in a MapReduce Job?
>
> --
> YANG, Lin
>
Re: How to get the number of node in cluster?
Posted by George Datskos <ge...@jp.fujitsu.com>.
Hey Jason,
This should return the number of active tasktrackers in the cluster:
int numNodes = new JobClient(conf).getClusterStatus().getTaskTrackers()
> Hi, all
>
> As I have to run my MapReduce program on clusters of different size,
> and I would like the reducer number adapt to (0.95 * NodeNo. *
> mapred.tasktracker.reduce.tasks.maximum) automatically, so I was
> wondering how to get get the number of node in cluster in a MapReduce Job?
>
> --
> YANG, Lin
>
Re: How to get the number of node in cluster?
Posted by George Datskos <ge...@jp.fujitsu.com>.
Hey Jason,
This should return the number of active tasktrackers in the cluster:
int numNodes = new JobClient(conf).getClusterStatus().getTaskTrackers()
> Hi, all
>
> As I have to run my MapReduce program on clusters of different size,
> and I would like the reducer number adapt to (0.95 * NodeNo. *
> mapred.tasktracker.reduce.tasks.maximum) automatically, so I was
> wondering how to get get the number of node in cluster in a MapReduce Job?
>
> --
> YANG, Lin
>
Re: How to get the number of node in cluster?
Posted by George Datskos <ge...@jp.fujitsu.com>.
Hey Jason,
This should return the number of active tasktrackers in the cluster:
int numNodes = new JobClient(conf).getClusterStatus().getTaskTrackers()
> Hi, all
>
> As I have to run my MapReduce program on clusters of different size,
> and I would like the reducer number adapt to (0.95 * NodeNo. *
> mapred.tasktracker.reduce.tasks.maximum) automatically, so I was
> wondering how to get get the number of node in cluster in a MapReduce Job?
>
> --
> YANG, Lin
>