Description of problem: nice command is ignored. I can see via the top command that two similar processes are using exactly the same CPU although their niceness is quite different (-1 vs. 19) How reproducible: try to prioritize two CPU-consuming tasks with nice or renice
The kernel interprets scheduling priority, assigning there.
If the nice command is no longer being used, it should probably get into the common bugs and/or release notes. (And the man pages for nice.) However, I'm not quite sure I understand. Is that what Bill's comment means? Is this Fedora only, or is this the case in all versions of Linux using later kernels?
I tested only Fedora and Salix (a kind of Slackware) and the latter works as expected, however it comes with kernel 2.6.37.6
I`ve just tested on latest Fedora 16 Beta that nice is still ignored
Works perfectly for me on Fedora 15. The niced task uses 10% and the normal one uses 90% of one CPU. Do you have multiple processors in that machine? If so, one task will run on each CPU and nice will not really have any effect. (I used taskset to force both onto one processor for testing.)
I don`t have multiple processors. By the way if you start processes from one terminal 'nice' might work as expected but otherwise not. http://forums.fedoraforum.org/showthread.php?t=266839&page=2
Sigh. This is almost certainly being caused by the cgroup autosched patch. (The same miracle patch that everyone clamored for because it helped with desktop interactivity.)
You should definitely disable sched_autogroup on computational servers and basically anywhere else you want to be able to use 'nice' usefully. echo "kernel.sched_autogroup_enabled = 0" >> /etc/sysctl.conf sysctl -p
You can also boot with the "noautogroup" kernel option to disable them. (Note that this really has nothing to do with systemd using cgroups to isolate things.) More interesting, you can renice the autogroups just like tasks: [cebbert@damacy /]$ cd /proc/9872 [cebbert@damacy 9872]$ cat autogroup /autogroup-199 nice 0 [cebbert@damacy 9872]$ echo -1 >autogroup bash: echo: write error: Operation not permitted [cebbert@damacy 9872]$ echo 19 >autogroup [cebbert@damacy 9872]$ cat autogroup /autogroup-199 nice 19
*** Bug 747488 has been marked as a duplicate of this bug. ***
This seems to be working as designed when taking sched_autogroup into account. There's really not much to fix here. Since there is a known workaround, we can close this out.