Re: Kernel 2.6.16 idle scheduling



On Monday 27 March 2006 13:40, you wrote:
> Hi,
>
> On Mon, 2006-03-27 at 07:32 -0600, Pat Double wrote:
> > On Monday 27 March 2006 06:51, Pat Double wrote:
> > > Kernel 2.6.16 has a new scheduling priority SCHED_IDLEPRIO. Currently
> > > beagled attempts to run some things using "ionice" but this requires
> > > root priviledges. SCHED_IDLEPRIO can be set by the user.
> > >
> > > Would it be acceptable to change beagled to use this instead of ionice
> > > when a 2.6.16 kernel is detected? How about beagled setting itself to
> > > this priority when started?
> >
> > OK, bad form replying to myself, but I was mistaken. It is the ck
> > patchset that has SCHED_IDLEPRIO. Still, I think it would be worthwhile
> > to investigate this. The patchset is popular.
>
> Is there any hope for this to go into the mainline kernel?  I'm
> reluctant to add support for it until it's in, because the API can
> change.  Anyone who ran Beagle before inotify went in can testify to
> that.

I understand, I probably would not have posted if I had originally remembered 
it was not in mainline. There are patches from this patchset that have made 
it into mainline in the past, I am unaware of the effort (or lack thereof) 
there may be to move these inline.

> The reason why ionice is root-only is because unprivileged processes can
> effectively block access to any other process by opening files and being
> unable to do any IO because other processes are using it.  Do you know
> if that DoS is possible with this patch?

I read about that. I do not know if the DoS is possible. Off the cuff I doubt 
it because this is a CPU priority, not an I/O priority. It only schedules CPU 
time to a process if the CPU is idle. So I do not see how it could block 
other processes, but then I'm not a kernel dev either. I'll look into it or 
ask on the mailing list.

> Thanks,
> Joe

-- 
Pat Double, pat patdouble com
"In the beginning God created the heaven and the earth."

Attachment: pgpIJL4dZKnuT.pgp
Description: PGP signature



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]