From: "Bryan Donlan" <bdonlan@gmail.com>
To: "Eric Descourtis" <desc0068@algonquincollege.com>
Cc: linux-kernel@vger.kernel.org, eric.des.courtis@gmail.com
Subject: Re: Limiting CPU usage for processes in linux 2.6.18.8
Date: Mon, 31 Mar 2008 11:25:32 -0400 [thread overview]
Message-ID: <3e8340490803310825r407f792fv9158c0a9ee7cda93@mail.gmail.com> (raw)
In-Reply-To: <fbb49c58d56e.47f0403c@algonquincollege.com>
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.
prev parent reply other threads:[~2008-03-31 15:25 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-03-31 1:37 Eric Descourtis
2008-03-31 15:25 ` Bryan Donlan [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=3e8340490803310825r407f792fv9158c0a9ee7cda93@mail.gmail.com \
--to=bdonlan@gmail.com \
--cc=desc0068@algonquincollege.com \
--cc=eric.des.courtis@gmail.com \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®