Have enough RAM on the slave that you can run your jobs plus Jenkins + some for 
overhead.
(e.g. 1GB of Jenkins slave, + #executors * ( 2GB for Maven +2GB for unit tests 
in forked VM) + OS overhead)
 Although this amount is mostly an overkill setting it too close to the 
threshold will slow your jobs down due to paging at best, or mean you get 
intermittent failures due to OOM at worst – (memory is generally cheaper that 
human time taken to investigate issues!)  (our maven jobs can be very memory 
hungry so your figures will vary)  (Note I recommend a single executor per 
slave)

The master depends more on how many jobs / reports per jobs / job history you 
have etc – we use 10GB (but not tomcat).

If you’re in the UK and there is any spaces left I will cover some things like 
this next week at the Jenkins User Event.

/James

From: jenkinsci-users@googlegroups.com 
[mailto:jenkinsci-users@googlegroups.com] On Behalf Of Jeff
Sent: 04 January 2013 21:56
To: jenkinsci-users@googlegroups.com
Subject: Master + slave + job JVM memory tuning...

I'm trying to optimize how much memory I allocate to the master application 
(aka - tomcat), slave processes, maven tasks, etc. and going crazy.

I've been unsuccessful in finding a guideline to determine how much memory I 
ought to allocate or if I should just let the defaults work.

All machines are single processor, dual core with 4 GB ram.

I've typically set tomcat to use 2048MB + 512MB permgen space and set my maven 
process to use 384MB max.  Is this reasonable?

My slaves are set to run 4 executors.  Jobs use either svn or git to check out 
code and Maven to build with a SONAR post-build analysis.  We also do Maven 
releases at times.

How much does the core slave process need?  Is there a "rule-of-thumb" based on 
the number of executors?

Any perspective/considerations/resources/links/pointers are much appreciated.

--
Jeff Vincent
predato...@gmail.com<mailto:predato...@gmail.com>
See my LinkedIn profile at:
http://www.linkedin.com/in/rjeffreyvincent
I ♥ DropBox<http://db.tt/9O6LfBX> !!

________________________________


**************************************************************************************
This message is confidential and intended only for the addressee. If you have 
received this message in error, please immediately notify the 
postmas...@nds.com and delete it from your system as well as any copies. The 
content of e-mails as well as traffic data may be monitored by NDS for 
employment and security purposes. To protect the environment please do not 
print this e-mail unless necessary.

NDS Limited. Registered Office: One London Road, Staines, Middlesex, TW18 4EX, 
United Kingdom. A company registered in England and Wales. Registered no. 
3080780. VAT no. GB 603 8808 40-00
**************************************************************************************

Reply via email to