[lxc-users] using cgroups

rob e redgerhoo at yahoo.com.au
Sat Jul 2 02:35:51 UTC 2016


On 02/07/16 12:14, Serge E. Hallyn wrote:
>> hi Serge,
>> with JUST those clauses (and no cgroup set clauses) ... it sort of
>> works. Initial messages are cleared from the console(?) leaving just
>> the shutdown messages. But it does get to a login prompt
> D'oh.  Thanks for your patience.  I see the bug.  I'll post a
> PR for a fix.  I'm surprised so few people run into this.  But
> as a workaround just add ",devices" to the end of the pam_cgfs
> line in /etc/pam.d/common-session.
>
sorry about this ... didn't work. Tried 2 forms of Pam clause & 2 forms 
of config

------------------------------------------------------
PAM line
session optional        pam_cgfs.so -c 
freezer,memory,name=systemd,cpuset,devices

Config elements
lxc.cgroup.memory.limit_in_bytes = 4G
lxc.cgroup.devices.allow =
lxc.cgroup.devices.deny =

$ lxc-start -n xenial_test_01 -F -o lxc_test_mem_160702c.log -l debug
lxc-start: cgfsng.c: cgfsng_setup_limits: 1645 No devices cgroup setup 
for xenial_test_01
lxc-start: start.c: lxc_spawn: 1226 failed to setup the devices cgroup 
for 'xenial_test_01'
lxc-start: start.c: __lxc_start: 1353 failed to spawn 'xenial_test_01'
            lxc-start: lxc_start.c: main: 344 The container failed to start.
lxc-start: lxc_start.c: main: 348 Additional information can be obtained 
by setting the --logfile and --logpriority options.


See attached log file lxc_test_mem_160702c.log
------------------------------------------------------
PAM line (no cpuset this time)
session optional        pam_cgfs.so -c freezer,memory,name=systemd,devices

Config elements
lxc.cgroup.memory.limit_in_bytes = 4G
lxc.cgroup.devices.allow =
lxc.cgroup.devices.deny =

$ lxc-start -n xenial_test_01 -F -o lxc_test_mem_160702d.log -l debug
lxc-start: cgfsng.c: cgfsng_setup_limits: 1645 No devices cgroup setup 
for xenial_test_01
lxc-start: start.c: lxc_spawn: 1226 failed to setup the devices cgroup 
for 'xenial_test_01'
lxc-start: start.c: __lxc_start: 1353 failed to spawn 'xenial_test_01'
            lxc-start: lxc_start.c: main: 344 The container failed to start.
lxc-start: lxc_start.c: main: 348 Additional information can be obtained 
by setting the --logfile and --logpriority options.

See attached log file lxc_test_mem_160702d.log

------------------------------------------------------
PAM line (no cpuset this time)
session optional        pam_cgfs.so -c freezer,memory,name=systemd,devices

Config elements (removed the extra test clauses)
lxc.cgroup.memory.limit_in_bytes = 4G

$ lxc-start -n xenial_test_01 -F -o lxc_test_mem_160702e.log -l debug
lxc-start: cgfsng.c: cgfsng_setup_limits: 1645 No devices cgroup setup 
for xenial_test_01
lxc-start: start.c: lxc_spawn: 1226 failed to setup the devices cgroup 
for 'xenial_test_01'
lxc-start: start.c: __lxc_start: 1353 failed to spawn 'xenial_test_01'
            lxc-start: lxc_start.c: main: 344 The container failed to start.
lxc-start: lxc_start.c: main: 348 Additional information can be obtained 
by setting the --logfile and --logpriority options.


See attached log file lxc_test_mem_160702e.log
-----------------------------------------------------

still trying :)

R
-------------- next part --------------
A non-text attachment was scrubbed...
Name: lxc_test_shall_mem_160702cde.zip
Type: application/zip
Size: 7876 bytes
Desc: not available
URL: <http://lists.linuxcontainers.org/pipermail/lxc-users/attachments/20160702/5c513af8/attachment-0001.zip>


More information about the lxc-users mailing list