pileofrogs has asked for the wisdom of the Perl Monks concerning the following question:

Monks! I call upon ye!

This is linux specific, so feel free to bypass this if you're not a linux type.

If you want to control a processes execution priority, you can use POSIX::nice(). I was looking for an equivalent when I ran across Completely Fair Queueing (CFQ), the io queueing system in modern linuxes. It does exactly what I want. You can control it with the utility 'ionice'. I didn't find anything on CPAN that allows control of CFQ, though.

So, my question is, is there a perl interface to CFQ?

Thanks!
--Pileofrogs

Replies are listed 'Best First'.
Re: CFQ / ionice ?
by kvale (Monsignor) on Nov 04, 2008 at 00:47 UTC
    If you are on Linux with CFQ/ionice installed, it is easy to invoke ionice through the shell:
    my $sched_class = 3; my $pid = 89; system "/usr/bin/ionice -c$sched_class -p$pid";

    -Mark