You are not logged in.

#1 2012-09-25 08:27:18

roywephy
Member
Registered: 2012-09-25
Posts: 2

autogroup patch 'breaks' "nice" command.

Hi all,

I just had a look how the nice command works together with the autogroup patch. (See i.e. this discussion: https://bbs.archlinux.org/viewtopic.php?id=108516, or the links at the end of the post).
While the default behaviour is consistent, it is rather annoying:

Nice works only inside a group, while my processes (i.e. compilation + some foreground task) run typically in different groups.

I hope someone can explain to me, what I am doing wrong. Processes are grouped by Session ID, and I get the following behaviour:

For me process priorities work now as follows:
- run several commands with different niceness levels from the same terminal: CPU time is divided according to niceness.
- run several commands with different niceness levels from different terminals:  Every command gets the same amount of CPU.
- run several commands with different niceness levels in the same terminal, and run more processes with different niceness levels in different terminals: CPU time is first divided between the terminals evenly, and then subdivided according to niceness.

Running several commands from the GUI works the same as running from different terminals, i.e. the SID is different, and niceness is therefore ignored.

I start X and login using inittab and lxdm.

An easy 'fix' for this is disabling autogroup support:
echo 0 > /proc/sys/kernel/sched_autogroup_enabled


Links on autogroup patch/cgroups:
https://wiki.archlinux.org/index.php/Cgroups
http://lwn.net/Articles/418884/

Offline

Board footer

Powered by FluxBB