libvirt cgroups

1 post / 0 new
#1 Fri, 2018-01-26 11:08
ks
  • ks's picture
  • Offline
  • Last seen: 2 months 3 days ago
  • Joined: 2018-01-25

Hello!

I have problem with libvirt and cgroups.

root@alpine-host:[~]: virsh cpu-stats centos7_devel

error: Failed to retrieve CPU statistics for domain 'centos7_devel'
error: Requested operation is not valid: cgroup CPUACCT controller is not mounted

root@alpine-host:[~]: cat /proc/mounts | grep cgroup

cgroup_root /sys/fs/cgroup tmpfs rw,nosuid,nodev,noexec,relatime,size=10240k,mode=755 0 0
openrc /sys/fs/cgroup/openrc cgroup rw,nosuid,nodev,noexec,relatime,release_agent=/lib/rc/sh/cgroup-release-agent.sh,name=openrc 0 0
cgroup /sys/fs/cgroup/devices cgroup rw,nosuid,nodev,noexec,relatime,devices 0 0
cgroup /sys/fs/cgroup/pids cgroup rw,nosuid,nodev,noexec,relatime,pids 0 0
cgroup /sys/fs/cgroup/net_cls,net_prio cgroup rw,nosuid,nodev,noexec,relatime,net_cls,net_prio 0 0
cgroup /sys/fs/cgroup/cpuset cgroup rw,nosuid,nodev,noexec,relatime,cpuset 0 0
cgroup /sys/fs/cgroup/cpu,cpuacct cgroup rw,nosuid,nodev,noexec,relatime,cpu,cpuacct 0 0
cgroup /sys/fs/cgroup/hugetlb cgroup rw,nosuid,nodev,noexec,relatime,hugetlb 0 0
cgroup /sys/fs/cgroup/freezer cgroup rw,nosuid,nodev,noexec,relatime,freezer 0 0
cgroup /sys/fs/cgroup/memory cgroup rw,nosuid,nodev,noexec,relatime,memory 0 0
cgroup /sys/fs/cgroup/perf_event cgroup rw,nosuid,nodev,noexec,relatime,perf_event 0 0
cgroup /sys/fs/cgroup/blkio cgroup rw,nosuid,nodev,noexec,relatime,blkio 0 0

root@alpine-host:[~]: ls -la /sys/fs/cgroup/

total 0
drwxr-xr-x 13 root root 340 Jan 26 17:54 .
drwxr-xr-x  6 root root   0 Jan 26 15:59 ..
dr-xr-xr-x  2 root root   0 Jan 26 17:52 blkio
lrwxrwxrwx  1 root root  11 Jan 26 17:54 cpu -> cpu,cpuacct
dr-xr-xr-x  2 root root   0 Jan 26 17:52 cpu,cpuacct
lrwxrwxrwx  1 root root  11 Jan 26 17:54 cpuacct -> cpu,cpuacct
dr-xr-xr-x  2 root root   0 Jan 26 17:52 cpuset
dr-xr-xr-x  2 root root   0 Jan 26 17:52 devices
dr-xr-xr-x  2 root root   0 Jan 26 17:52 freezer
dr-xr-xr-x  2 root root   0 Jan 26 17:52 hugetlb
dr-xr-xr-x  2 root root   0 Jan 26 17:52 memory
lrwxrwxrwx  1 root root  16 Jan 26 17:54 net_cls -> net_cls,net_prio
dr-xr-xr-x  2 root root   0 Jan 26 17:52 net_cls,net_prio
lrwxrwxrwx  1 root root  16 Jan 26 17:54 net_prio -> net_cls,net_prio
dr-xr-xr-x 11 root root   0 Jan 26 15:59 openrc
dr-xr-xr-x  2 root root   0 Jan 26 17:52 perf_event
dr-xr-xr-x  2 root root   0 Jan 26 17:52 pids