Jenkins doesn't recognize "nice" because that's a Unix-only feature; I'm not 
sure if there is an equivalent Windows feature.  Of course, if your steps are 
shells, you can tell those to nice themselves.  You could also "nice" your 
slave nodes when you launch them, if you do so by script.  Niceness is 
inherited, so a slave node running at a given nice level will run jobs at that 
same nice level.
Jenkins itself tends to be rather light on the CPU, but it takes up networking 
resources and disk I/O because it receives output from the jobs it runs and 
logs them.  Idle slaves are light, and a slave in use only adds a little 
overhead, mostly the network traffic of sending logs back to the server.
When you configure a job, it has an "Execute concurrent builds if necessary" 
flag.  With that turned on, you can run more than one in parallel.
If you want some jobs to be "nicer" than others on the same machine, you can 
use the Jenkins Heavy Job Plugin.  Basically, while a normal job takes up one 
executor (a node can have one or more executors, each capable of running a 
job), a heavy job can take up multiple ones.  So if you have job A (an easy 
one) and job B (a resource hog), you can tell Jenkins that Job B has a "weight" 
of (say) 3.  If you had a node with four executors, this would mean:
1: Job B would not run until there are three free executors, so it would wait 
until no more than one copy of job A was running
2: Job B would take up three executors, so when it was running, Jenkins would 
put no more than one copy of job A on that node, and not another version of job 
B (to run two job B's on the same node, you'd need at least six executors).

Hope this helps,

--Rob

From: jenkinsci-users@googlegroups.com 
[mailto:jenkinsci-users@googlegroups.com] On Behalf Of Roberto Nunnari
Sent: Wednesday, June 13, 2012 4:35 AM
To: jenkinsci-users
Subject: build processes priority?

Hi everybody.

I wonder how heavy the build processes are on the cpu..

I set up a single machine offering many different services (also including 
jenkins webapp) and I'm worrying a bit about overall performance when jenkins 
will enter production stage.

Being a virtual machine, I will be able to add one virtual cpu if the load will 
be too much.. but I wonder if it also possible to set some configuration option 
so that the build processes are started with a high nice value. Another option 
I can think of would be to start jenkins main process with a nice value, but I 
don't know if that will be considered when jenkins will span the build 
processes.

So..
1) build processes can be run at a lower priority?
2) If yes, how?
3) build processes will be run one at a time or more than one in parallel?

Could anybody please cast some light on this?

Thank you and best regards.

The information in this message is for the intended recipient(s) only and may 
be the proprietary and/or confidential property of Litle & Co., LLC, and thus 
protected from disclosure. If you are not the intended recipient(s), or an 
employee or agent responsible for delivering this message to the intended 
recipient, you are hereby notified that any use, dissemination, distribution or 
copying of this communication is prohibited. If you have received this 
communication in error, please notify Litle & Co. immediately by replying to 
this message and then promptly deleting it and your reply permanently from your 
computer.

Reply via email to