* Limiting CPU usage for processes in linux 2.6.18.8
@ 2008-03-31 1:37 Eric Descourtis
2008-03-31 15:25 ` Bryan Donlan
0 siblings, 1 reply; 2+ messages in thread
From: Eric Descourtis @ 2008-03-31 1:37 UTC (permalink / raw)
To: linux-kernel; +Cc: eric.des.courtis
Hello,
I would like to implement a patch to the scheduler that limits the CPU usage of individual
processes to a percentage in Linux 2.6.18.8 (Can't be any other version).
I would just like some feedback on the following questions:
1. How can I ensure that limited processes get their CPU time percentage allocation?
2. Are there mechanisms in place that would simplify this process?
I have been hitting my head against the wall for a long time now, any help would be appreciated.
Thank you.
Eric des Courtis
CC: eric.des.courtis@gmail.com
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Limiting CPU usage for processes in linux 2.6.18.8
2008-03-31 1:37 Limiting CPU usage for processes in linux 2.6.18.8 Eric Descourtis
@ 2008-03-31 15:25 ` Bryan Donlan
0 siblings, 0 replies; 2+ messages in thread
From: Bryan Donlan @ 2008-03-31 15:25 UTC (permalink / raw)
To: Eric Descourtis; +Cc: linux-kernel, eric.des.courtis
On Sun, Mar 30, 2008 at 9:37 PM, Eric Descourtis
<desc0068@algonquincollege.com> wrote:
> Hello,
>
> I would like to implement a patch to the scheduler that limits the CPU usage of individual
> processes to a percentage in Linux 2.6.18.8 (Can't be any other version).
> I would just like some feedback on the following questions:
>
> 1. How can I ensure that limited processes get their CPU time percentage allocation?
> 2. Are there mechanisms in place that would simplify this process?
>
> I have been hitting my head against the wall for a long time now, any help would be appreciated.
The scheduler isn't really designed to force programs to idle when
there's nothing else to run - that would be a waste :)
If the reason you're on 2.6.18.8 is for Xen, you might want to try
using a recent kernel with paravirt ops, and use the CFS fair group
(or user) scheduler to set cpu shares. See
Documentation/sched-design-CFS.txt . If you really want to eat up a
certain portion of CPU time doing nothing, you could create a program
to busy-loop to starve the others and set CPU shares appropriately,
though I don't really see the point in that.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2008-03-31 15:25 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-03-31 1:37 Limiting CPU usage for processes in linux 2.6.18.8 Eric Descourtis
2008-03-31 15:25 ` Bryan Donlan
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox