Your message dated Thu, 25 Aug 2016 19:21:31 +0000 with message-id <[email protected]> and subject line Bug#799541: fixed in lxc 1:2.0.4-1 has caused the Debian Bug report #799541, regarding lxc-stop kills Debian 7 upgraded containers to Debian 8 with systemd on a Debian 8 host to be marked as done.
This means that you claim that the problem has been dealt with. If this is not the case it is now your responsibility to reopen the Bug report if necessary, and/or fix the problem forthwith. (NB: If you are a system administrator and have no idea what this message is talking about, this may indicate a serious mail system misconfiguration somewhere. Please contact [email protected] immediately.) -- 799541: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=799541 Debian Bug Tracking System Contact [email protected] with problems
--- Begin Message ---Package: lxc Version: 1:1.0.6-6+deb8u1 Hi, On a D8 host server with D7 containers upgraded to D8 with systemd - following the instructions from the LXC Debian page. When I use lxc-stop command to cleanly stop a container, it waits, times out and finally kills the container instead of issuing a clean shutdown. The pb does not happen on native D8 containers. Here is a transcript: #lxc-stop -n mylxcbox This is what lxc-checkconfig returns: [all green] =================================================== # lxc-checkconfig Kernel configuration not found at /proc/config.gz; searching... Kernel configuration found at /boot/config-3.16.0-4-amd64 --- Namespaces --- Namespaces: enabled Utsname namespace: enabled Ipc namespace: enabled Pid namespace: enabled User namespace: enabled Network namespace: enabled Multiple /dev/pts instances: enabled --- Control groups --- Cgroup: enabled Cgroup clone_children flag: enabled Cgroup device: enabled Cgroup sched: enabled Cgroup cpu account: enabled Cgroup memory controller: enabled Cgroup cpuset: enabled --- Misc --- Veth pair device: enabled Macvlan: enabled Vlan: enabled File capabilities: enabled =================================================== This is the configuration of the container [nothing really fancy here] =================================================== cat /var/lib/lxc/mylxcbox/config lxc.network.type = empty lxc.rootfs = /var/lib/lxc/mylxcbox/rootfs # Common configuration lxc.include = /usr/share/lxc/config/debian.common.conf # Container specific configuration lxc.mount = /var/lib/lxc/mylxcbox/fstab lxc.utsname = mylxcbox lxc.arch = amd64 lxc.autodev = 1 lxc.kmsg = 0 lxc.network.type = veth lxc.network.flags = up lxc.network.link = vbr0 lxc.network.ipv4 = 192.168.10.200/24 lxc.network.hwaddr = 00:1E:62:CH:NG:ME # RAM lxc.cgroup.memory.limit_in_bytes = 2G =================================================== # lxc-monitor -n mylxcbox --logpriority=DEBUG 'mylxcbox' exited with status [0] 'mylxcbox' changed state to [STOPPING] 'mylxcbox' changed state to [STOPPED] status 0 indicates the container was successfully stopped but it does it after timing out: I can verify this starting the container in non deamon mode [lxc-start -n mylxcbox] The services are not stopping, everything is killed after 60 seconds. # time lxc-stop -n mylxcbox real 1m0.146s user 0m0.000s sys 0m0.004s It takes 60 seconds which means the container is killed after a 60 seconds timeout. With the --nokill option added, the command times out but the container remains up and running [ie: not killed]. As per manpage documentation: DESCRIPTION lxc-stop reboots, cleanly shuts down, or kills all the processes inside the container. By default, it will request a clean shutdown of the container by sending lxc.haltsig nal (defaults to SIGPWR) to the container's init process, waiting up to 60 seconds for the container to exit, and then returning. If the container fails to cleanly exit in 60 seconds, it will be sent the lxc.stopsignal (defaults to SIGKILL) to force it to shut down. What could prevent lxc.haltsignal (defaults to SIGPWR) to reach an upgraded D7 container to D8 with systemd ? This is the solution/workaround I have found [took me 2 days] and which will hopefully help you resolve the matter: Changing the halt signal from the default (SIGPWR) to SIGRTMIN+4 by adding the following configuration in the container config file: allows me to shutdown the container with lxc-stop but also in a clean manner with services being stopped as expected. The two identified signals to request a clean shutdown [#1] and an immediate halt[#2] for the D7 to D8 systemd containers are: # modified signals for D7 containers upgraded to D8 lxc.haltsignal = SIGRTMIN+4 #1 lxc.stopsignal = SIGRTMIN+14 #2 I am using Linux 3.16.0-4-amd64 #1 SMP Debian 3.16.7-ckt11-1+deb8u3 (2015-08-04) x86_64 GNU/Linux The server and containers are frequently updated, all stable with debian-security. -- Cheers, Nulld1g1t Nulld1g1t Blog: http://www.yourprog.com Nulld1g1t Youtube channel: https://www.youtube.com/user/nulld1g1t Twitter: https://twitter.com/nulld1g1t
0x6CF19A40.asc
Description: application/pgp-keys
signature.asc
Description: OpenPGP digital signature
--- End Message ---
--- Begin Message ---Source: lxc Source-Version: 1:2.0.4-1 We believe that the bug you reported is fixed in the latest version of lxc, which is due to be installed in the Debian FTP archive. A summary of the changes between this version and the previous one is attached. Thank you for reporting the bug, which will now be closed. If you have further comments please address them to [email protected], and the maintainer will reopen the bug report if appropriate. Debian distribution maintenance software pp. Evgeni Golov <[email protected]> (supplier of updated lxc package) (This message was generated automatically at their request; if you believe that there is a problem with it please contact the archive administrators by mailing [email protected]) -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA512 Format: 1.8 Date: Thu, 25 Aug 2016 19:52:33 +0200 Source: lxc Binary: lxc lxc-dbg lxc-dev liblxc1 Architecture: source Version: 1:2.0.4-1 Distribution: unstable Urgency: medium Maintainer: pkg-lxc <[email protected]> Changed-By: Evgeni Golov <[email protected]> Description: liblxc1 - Linux Containers userspace tools (library) lxc - Linux Containers userspace tools lxc-dbg - Linux Containers userspace tools (debug) lxc-dev - Linux Containers userspace tools (development) Closes: 799541 806746 831691 Changes: lxc (1:2.0.4-1) unstable; urgency=medium . [ Antonio Terceiro ] * debian/rules: create symlinks for each lxc-* binary in /usr/share/bash-completion/completions/ so that bash completion actually works . [ Evgeni Golov ] * Imported Upstream version 2.0.4 + Uses SIGRTMIN+3 for systemd containers (Closes: #831691, #799541) + The debian template properly generates locaes (Closes: #806746) * drop 0020-fix-regression-when-creating-wheezy-containers.patch * rebase patches ontop of 2.0.4 * add gnupg and dirmngr to recommends * improve autopkgtest execution, making most autopkgtest run properly Checksums-Sha1: dfeb019c8334cbdde1018d56d2ea384c55d38aad 2442 lxc_2.0.4-1.dsc 3e05099104fea188258c834dd5f4f99433955ebd 1065905 lxc_2.0.4.orig.tar.gz cf3fe3b6830f62a96f2466cb1674c10e44bef7c4 81900 lxc_2.0.4-1.debian.tar.xz Checksums-Sha256: 03657071cccff215cc232fb924bf8abc65f7d9c7ffed8734a8d464e15922d684 2442 lxc_2.0.4-1.dsc 14c9e699a4bf4e23a420922eb5ae3e163bb151c3d2bf6a3dcbea48c2dd3e9582 1065905 lxc_2.0.4.orig.tar.gz 2955a44bba2c04c2a7e474aa4dfa95d4627d1b0a3bc91cc1f3ccb12ff490f689 81900 lxc_2.0.4-1.debian.tar.xz Files: b8a78cb0b56c2559b124cca451ebad27 2442 admin optional lxc_2.0.4-1.dsc 28db4dbacf860ae742138c0ed8dbf14c 1065905 admin optional lxc_2.0.4.orig.tar.gz 3874345cbcd6e8978d7cc8675aa7239f 81900 admin optional lxc_2.0.4-1.debian.tar.xz -----BEGIN PGP SIGNATURE----- iQIcBAEBCgAGBQJXv0JOAAoJEKGwm0IzOWHo8/cQALMTMd2TLPlkrwyvRNeve1ZA 6HqgZq/VqNWXQBK4p7TuikQMIMcTbHqP+659r6FPUvoNWOIPILjipka8fu6d9Q1+ VP6i4nHf5bj9fY1Q+AGSupFJ+IzZWedlCufncNVWv5g+kDu/9tPKirMIuScZP3et sbsqQ5aYi5XYaLIAXd5HzceN9/OEtbbrE/yFHcJSChePw0+WUzRIfCjgSbq0Uneo /JuZpsyLxWR0LIHBitpqkJ54n5YwNkt+1XOOncC1VHaReWOZJKg8Cqw7Ff4gWsKz Wl+DZSFaN10MrLJbudBMUsTbew4hpeLR1qS9G2zvohiErQG3+0ZSMloeOUdrO7qC 2O6Fj40RHozFdKJHaq7uIgTYEFId3Jm6NtEZTw6dDkwWmKiZJRmvcLbQYOAbUnmZ GV728WjLEPWoOlYFlHvYPQIwcHtgZvnt4JkWzuEOewrUpl1lr/ZSQuYe57WG98F7 hkYESzfT2xEKn1Gqr5c7lYNy522WGdDZ0CLc1i73JcNpIyj+ukOPObBJGFj7SNC6 jj3Qr49PevnujDFAZ7NQgDlU9qu4RX8OTvnbQH1qgBeyM0kOhy3IdgARyKuRzWM9 GJLA1Z9LcCovObNMiXDFq21alPZbkWhA/8TjAbDsuf3CcNwNkK3sfHXx2xRj3Utq aoYgsr2wKO/Mb8vh3/Ff =cMW5 -----END PGP SIGNATURE-----
--- End Message ---

