Package: dpkg Version: 1.16.10 Severity: normal Hi
I noticed services not starting at boot and failed to start when manually started via init scripts. On further investigation this appears S-S-D interacts badly with LXC containers. To illistrate, when a daemon is running in an LXC container, S-S-D believes it is already running on the host, hence when refuses to start them. For example, manually executing (with --verbose) the same as happens in the snmpd init script: # start-stop-daemon --verbose --start --oknodo --exec /usr/sbin/snmpd -- -LS n d -Lf /dev/null -u snmp -g snmp -I -smux -p /var/run/snmpd.pid /usr/sbin/snmpd already running. # ps ax|grep snmpd 11346 ? S 0:00 /usr/sbin/snmpd -LS n d -Lf /dev/null -u snmp -g snmp -I -smux -p /var/run/snmpd.pid 11400 ? S 0:00 /usr/sbin/snmpd -LS n d -Lf /dev/null -u snmp -g snmp -I -smux -p /var/run/snmpd.pid 30383 pts/23 S+ 0:00 grep snmpd However these two snmpd processes are running in LXC containers, not the host: # cat /proc/11346/cgroup 1:perf_event,blkio,net_cls,freezer,devices,cpuacct,cpu,cpuset:/lxc/<CONTAINERNAME1> # cat /proc/11400/cgroup 1:perf_event,blkio,net_cls,freezer,devices,cpuacct,cpu,cpuset:/lxc/<CONTAINERNAME2> Likewise, if a service is stopped on the host via S-S-D (init script), it wipes out all the matching daemons on the LXC containers as well: # ps ax|grep snmpd 2460 pts/23 S+ 0:00 grep snmpd 11346 ? S 0:01 /usr/sbin/snmpd -LS n d -Lf /dev/null -u snmp -g snmp -I -smux -p /var/run/snmpd.pid 11400 ? S 0:01 /usr/sbin/snmpd -LS n d -Lf /dev/null -u snmp -g snmp -I -smux -p /var/run/snmpd.pid # /etc/init.d/snmpd stop Stopping network management services: snmpd snmptrapd. # ps ax|grep snmpd 2484 pts/23 S+ 0:00 grep snmpd While this may not affect a large proportion of users, it risks crippling the host system if critical services start on a container before the host at boot. Thanks Glen -- System Information: Debian Release: 7.1 APT prefers stable-updates APT policy: (500, 'stable-updates'), (500, 'stable') Architecture: amd64 (x86_64) Kernel: Linux 3.2.0-4-amd64 (SMP w/2 CPU cores) Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/dash Versions of packages dpkg depends on: ii libbz2-1.0 1.0.6-4 ii libc6 2.13-38 ii liblzma5 5.1.1alpha+20120614-2 ii libselinux1 2.1.9-5 ii tar 1.26+dfsg-0.1 ii zlib1g 1:1.2.7.dfsg-13 dpkg recommends no packages. Versions of packages dpkg suggests: ii apt 0.9.7.9 -- no debconf information -- To UNSUBSCRIBE, email to [email protected] with a subject of "unsubscribe". Trouble? Contact [email protected]

