Dear friends,
I'm on ubuntu 12.10, trying to configure cgroups to restrict memory usage on a per-application basis. Basically I have some programs that are unimportant in nearly every concievable way, but which I still need running in the background---and they're using more physical memory than I want them to, so i'd like to either:
a) relegate them to a swapfile (I have no swap partition)
b) make less memory available for them to use.
Everything I've found suggests that cgroups is the only path for me to take at this moment, and I've been trying for days but can't make any progress.
My basic steps have been:
Code:
sudo apt-get install cgroups-bin
editing /etc/cgroups.conf to contain
Code:
group limited {
memory {
memory.limit_in_bytes = 1024M;
}
}
and then rebooting. But on reboot, the cgroup 'limited' doesn't exist in /sys/fs/cgroup/memory. This is sort of expected because most guides and instructions on the internet suggest that /etc/cgroups.conf is created when installing cgroups, but this was not the case for me on 12.10, I had to create the file myself.
The documentation is so poor on this subject, and I don't understand it all that well to begin with, so your assistance is greatly appreciated!
Best
e