[lxc-users] [LXD] how to add cgroup options using lxc

Mark Constable markc at renta.net
Wed Mar 18 04:03:07 UTC 2015


Ubuntu vivid w/ lxd-daily.

When setting up unprivileged containers via lxc-create these cgroup
settings come from ~/.config/lxc/default.conf and for the most part
seem to work.
  
lxc.cgroup.memory.soft_limit_in_bytes = 256M
lxc.cgroup.memory.limit_in_bytes = 512M
lxc.cgroup.memory.memsw.limit_in_bytes = 256M
lxc.cgroup.cpu.shares = 256
lxc.cgroup.blkio.weight = 500
lxc.cgroup.cpuset.cpus = 7

How do I translate the above settings for the lxc config command so
these same values end up in /var/lib/lxd/lxd.db?


More information about the lxc-users mailing list