[vserver] Cgroups - kernel configuration

From: Markus Petzsch <m.petzsch_at_net-hoster.de>
Date: Sun 31 Jan 2010 - 13:24:20 GMT
Message-ID: <4B658484.1080701@net-hoster.de>

Hi,

I'm trying to enforce hard cpu limits with cgroups following these
instructions:
http://linux-vserver.org/util-vserver:Cgroups

I've used a defailt debian testing kernel and have the following vserver
specific configurations set:

CONFIG_CFS_HARD_LIMITS=y
# Linux VServer
CONFIG_VSERVER_AUTO_LBACK=y
# CONFIG_VSERVER_AUTO_SINGLE is not set
CONFIG_VSERVER_COWBL=y
# CONFIG_VSERVER_VTIME is not set
# CONFIG_VSERVER_DEVICE is not set
CONFIG_VSERVER_PROC_SECURE=y
CONFIG_VSERVER_HARDCPU=y
CONFIG_VSERVER_IDLETIME=y
CONFIG_VSERVER_IDLELIMIT=y
CONFIG_VSERVER_PRIVACY=y
CONFIG_VSERVER_CONTEXTS=768
CONFIG_VSERVER_WARN=y
# CONFIG_VSERVER_DEBUG is not set
CONFIG_VSERVER=y
CONFIG_VSERVER_SECURITY=y
CONFIG_CGROUP_SCHED=y
CONFIG_CGROUPS=y
# CONFIG_CGROUP_DEBUG is not set
# CONFIG_CGROUP_NS is not set
CONFIG_CGROUP_FREEZER=y
CONFIG_CGROUP_DEVICE=y
CONFIG_CGROUP_CPUACCT=y
CONFIG_NET_CLS_CGROUP=y

Here my cgroup specific settings on vserver1:
cpu.cfs_hard_limit 1
cpu.cfs_period_us 500000
cpu.cfs_runtime_us 250000

when first trying to start my vserver i get the following error:
/usr/lib/util-vserver/vserver.functions: Zeile 1490:
/dev/cgroup/vserver1/cpu.cfs_hard_limit: Keine Berechtigung

Failed to start vserver 'vserver1'

on the second try it just starts. But tests with md5sum /dev/urandom
show that there is no cpu limiting in place.

I'm using util-vserver version 0.30.216-pre2864-1 (deliverd with debian
testing/squeeze).

Hope you have an idea what is wrong with my setup.

Regards

Markus Petzsch
Received on Sun Jan 31 13:24:03 2010

[Next/Previous Months] [Main vserver Project Homepage] [Howto Subscribe/Unsubscribe] [Paul Sladen's vserver stuff]
Generated on Sun 31 Jan 2010 - 13:24:07 GMT by hypermail 2.1.8