CGroups for resource management

| No Comments | No TrackBacks
Steven Ellis is talking about cgroups. CGroups are about an in kernel feature and userspace tools and librarys to manage how resources are allocated to users and processes. Resources are disk, network and CPU.

His first example was resource management for virtual guests, but said you could do the same for running a server with multiple databases. You can uses memory, cpuset, cpuacct, cpu and other controllers (devices, network, etc). It's a heirarchy, so you can allocate a restriction to all daemons, or all http instances, and child processes inherit the restrictions. So you could set http to only have 30% of the memory. Or you can measure the number of cpu cycles. 

THere are a bunch of command line tools, that all start with 'cg'. File is in /etc/cgconfig.conf. Redhat have a way of setting CGROUP_DAEMON variables under /etc/sysconfig so that as the daemon is started it is immediately limited by that CGroup setting.

There is some kind of cgroups daemon for managing stuff based on which userid or groupid is used. 

No TrackBacks

TrackBack URL:

Leave a comment

About this Entry

This page contains a single entry by Geoff Crompton published on January 25, 2011 5:55 PM.

tuning postgresql was the previous entry in this blog.

Varnish and HTTP acceleration is the next entry in this blog.

Find recent content on the main index or look in the archives to find all content.



Powered by Movable Type 4.23-en