Recent discussion on the lkm has lead to Linus giving the go-ahead to a large kernel patch that massively increases responsiveness when multi-tasking on Linux desktop. A slashdot article today also points out that the same result can be achieved by modifications userspace and that this is, indeed, how the patch was tested.
The original instructions can be found at webupd8, but, for Ubuntu systems, they are incomplete.
Here's the correct information.
/etc/rc.local should contain:
mkdir -p /dev/cgroup/cpu
mount -t cgroup cgroup /dev/cgroup/cpu -o cpu
mkdir -m 0777 /dev/cgroup/cpu/user
echo "/usr/local/sbin/cgroup_clean" > /dev/cgroup/cpu/release_agent
and should be executable (sudo chmod +x /etc/rc.local).
Your ~/.bashrc should contain:
if [ "$PS1" ] ; then
mkdir -p -m 0700 /dev/cgroup/cpu/user/$$ > /dev/null 2>&1
echo $$ > /dev/cgroup/cpu/user/$$/tasks
echo "1" > /dev/cgroup/cpu/user/$$/notify_on_release
directly at the top.
Finally (and this is where the original instructions were incomplete), /usr/local/sbin/cgroup_clean should contain:
if [ "$1" != "/user" ]; then
as suggested by an anonymous comment on the original. Finally, ensure the cgroup cleanup script is executable: sudo chmod +x /usr/local/sbin/cgroup_clean
Reboot your system and you too can have an ultra-responsive desktop!