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 Mike S <mi...@gmail.com> on 2012/08/29 04:10:42 UTC

heap size for the job tracker

1> Can I change the heap size for the job tracker only if I am using
version 1.0.2?

2>  If so, would you please say what exact line I should put in the
hadoop-evv.sh and where ? Should I set the value with a number or use
the Xmx notion?

I mean which one is the correct way

export HADOOP_HEAPSIZE=2000

or

export HADOOP_HEAPSIZE="-Xmx2000m"

3> Do I need to restart the job tracker node or call start-mapred.sh
to make the heap size change to take in effect? Is there anything else
I need to do to make the change to be applied?

Re: heap size for the job tracker

Posted by Harsh J <ha...@cloudera.com>.
Hi Mike,

On Wed, Aug 29, 2012 at 7:40 AM, Mike S <mi...@gmail.com> wrote:
> 1> Can I change the heap size for the job tracker only if I am using
> version 1.0.2?

Yes.

> 2>  If so, would you please say what exact line I should put in the
> hadoop-evv.sh and where ? Should I set the value with a number or use
> the Xmx notion?
>
> I mean which one is the correct way
>
> export HADOOP_HEAPSIZE=2000
>
> or
>
> export HADOOP_HEAPSIZE="-Xmx2000m"

The above (first one is right syntax) changes the heap across _all_
daemons, not just JT specifically. So you don't want to do that.

You may instead find and change the below line in hadoop-env.sh to the
following:

export HADOOP_JOBTRACKER_OPTS="$HADOOP_JOBTRACKER_OPTS -Xmx2g"

> 3> Do I need to restart the job tracker node or call start-mapred.sh
> to make the heap size change to take in effect? Is there anything else
> I need to do to make the change to be applied?

You will need to restart the JobTracker JVM for the new heap limit to
get used. You can run "hadoop-daemon.sh stop jobtracker" followed by
"hadoop-daemon.sh start jobtracker" to restart just the JobTracker
daemon (run the command on the JT node).

-- 
Harsh J