Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Bug#910637: installation failure

113 views
Skip to first unread message

Harald Dunkel

unread,
Oct 9, 2018, 4:00:04 AM10/9/18
to
Package: libnss-mdns
Version: 0.10-8

Apparently installing libnss-mdns on Stretch in a LXC container fails with
a catch22:

root@cups01:~# apt install libnss-mdns
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following additional packages will be installed:
avahi-daemon libavahi-core7 libdaemon0
Suggested packages:
avahi-autoipd avahi-autoipd | zeroconf
The following NEW packages will be installed:
avahi-daemon libavahi-core7 libdaemon0 libnss-mdns
0 upgraded, 4 newly installed, 0 to remove and 0 not upgraded.
Need to get 0 B/245 kB of archives.
After this operation, 739 kB of additional disk space will be used.
Do you want to continue? [Y/n]
Selecting previously unselected package libdaemon0:amd64.
(Reading database ... 22579 files and directories currently installed.)
Preparing to unpack .../libdaemon0_0.14-6_amd64.deb ...
Unpacking libdaemon0:amd64 (0.14-6) ...
Selecting previously unselected package libavahi-core7:amd64.
Preparing to unpack .../libavahi-core7_0.6.32-2_amd64.deb ...
Unpacking libavahi-core7:amd64 (0.6.32-2) ...
Selecting previously unselected package avahi-daemon.
Preparing to unpack .../avahi-daemon_0.6.32-2_amd64.deb ...
Unpacking avahi-daemon (0.6.32-2) ...
Selecting previously unselected package libnss-mdns:amd64.
Preparing to unpack .../libnss-mdns_0.10-8_amd64.deb ...
Unpacking libnss-mdns:amd64 (0.10-8) ...
Setting up libdaemon0:amd64 (0.14-6) ...
Processing triggers for libc-bin (2.24-11+deb9u3) ...
Processing triggers for systemd (232-25+deb9u4) ...
Processing triggers for man-db (2.7.6.1-2) ...
Processing triggers for dbus (1.10.26-0+deb9u1) ...
Setting up libavahi-core7:amd64 (0.6.32-2) ...
Setting up avahi-daemon (0.6.32-2) ...
Created symlink /etc/systemd/system/dbus-org.freedesktop.Avahi.service -> /lib/systemd/system/avahi-daemon.service.
Created symlink /etc/systemd/system/multi-user.target.wants/avahi-daemon.service -> /lib/systemd/system/avahi-daemon.service.
Created symlink /etc/systemd/system/sockets.target.wants/avahi-daemon.socket -> /lib/systemd/system/avahi-daemon.socket.
Job for avahi-daemon.service failed because the control process exited with error code.
See "systemctl status avahi-daemon.service" and "journalctl -xe" for details.
invoke-rc.d: initscript avahi-daemon, action "start" failed.
* avahi-daemon.service - Avahi mDNS/DNS-SD Stack
Loaded: loaded (/lib/systemd/system/avahi-daemon.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Tue 2018-10-09 09:43:41 CEST; 7ms ago
Process: 1545 ExecStart=/usr/sbin/avahi-daemon -s (code=exited, status=255)
Main PID: 1545 (code=exited, status=255)

Oct 09 09:43:41 cups01.example.com systemd[1]: Starting Avahi mDNS/DNS-SD Stack...
Oct 09 09:43:41 cups01.example.com systemd[1]: avahi-daemon.service: Main process exited, code=exited, status=255/n/a
Oct 09 09:43:41 cups01.example.com systemd[1]: Failed to start Avahi mDNS/DNS-SD Stack.
Oct 09 09:43:41 cups01.example.com systemd[1]: avahi-daemon.service: Unit entered failed state.
Oct 09 09:43:41 cups01.example.com systemd[1]: avahi-daemon.service: Failed with result 'exit-code'.
dpkg: error processing package avahi-daemon (--configure):
subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of libnss-mdns:amd64:
libnss-mdns:amd64 depends on avahi-daemon (>= 0.6.16-1); however:
Package avahi-daemon is not configured yet.

dpkg: error processing package libnss-mdns:amd64 (--configure):
dependency problems - leaving unconfigured
Processing triggers for libc-bin (2.24-11+deb9u3) ...
Processing triggers for dbus (1.10.26-0+deb9u1) ...
Processing triggers for systemd (232-25+deb9u4) ...
Errors were encountered while processing:
avahi-daemon
libnss-mdns:amd64
[master 21b2711] committing changes in /etc after apt run
26 files changed, 286 insertions(+), 4 deletions(-)
create mode 100644 avahi/avahi-daemon.conf
create mode 100644 avahi/hosts
create mode 100644 dbus-1/system.d/avahi-dbus.conf
create mode 100644 default/avahi-daemon
create mode 100755 init.d/avahi-daemon
create mode 120000 network/if-post-down.d/avahi-daemon
create mode 100755 network/if-up.d/avahi-daemon
create mode 120000 rc0.d/K01avahi-daemon
create mode 120000 rc1.d/K01avahi-daemon
create mode 120000 rc2.d/S01avahi-daemon
create mode 120000 rc3.d/S01avahi-daemon
create mode 120000 rc4.d/S01avahi-daemon
create mode 120000 rc5.d/S01avahi-daemon
create mode 120000 rc6.d/K01avahi-daemon
create mode 100755 resolvconf/update-libc.d/avahi-daemon
create mode 120000 systemd/system/dbus-org.freedesktop.Avahi.service
create mode 120000 systemd/system/multi-user.target.wants/avahi-daemon.service
create mode 120000 systemd/system/sockets.target.wants/avahi-daemon.socket
E: Sub-process /usr/bin/dpkg returned an error code (1)


Here are the logfiles:

* avahi-daemon.service - Avahi mDNS/DNS-SD Stack
Loaded: loaded (/lib/systemd/system/avahi-daemon.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Tue 2018-10-09 09:43:41 CEST; 2min 51s ago
Main PID: 1545 (code=exited, status=255)

Oct 09 09:43:41 cups01.example.com systemd[1]: Starting Avahi mDNS/DNS-SD Stack...
Oct 09 09:43:41 cups01.example.com systemd[1]: avahi-daemon.service: Main process exited, code=exited, status=255/n/a
Oct 09 09:43:41 cups01.example.com systemd[1]: Failed to start Avahi mDNS/DNS-SD Stack.
Oct 09 09:43:41 cups01.example.com systemd[1]: avahi-daemon.service: Unit entered failed state.
Oct 09 09:43:41 cups01.example.com systemd[1]: avahi-daemon.service: Failed with result 'exit-code'.
root@cups01:~# journalctl -xe
Oct 09 09:43:41 cups01.example.com systemd[1]: sys-devices-virtual-net.mount: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: systemd-user-sessions.service: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: ssh.service: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: Reloaded D-Bus System Message Bus.
-- Subject: Unit dbus.service has finished reloading its configuration
-- Defined-By: systemd
-- Support: https://www.debian.org/support
--
-- Unit dbus.service has finished reloading its configuration
--
-- The result is done.
Oct 09 09:43:41 cups01.example.com systemd[1]: Reloading.
Oct 09 09:43:41 cups01.example.com systemd[1]: anacron.timer: Adding 2min 11.663469s random time.
Oct 09 09:43:41 cups01.example.com systemd[1]: apt-daily-upgrade.timer: Adding 3min 28.887448s random time.
Oct 09 09:43:41 cups01.example.com systemd[1]: apt-daily.timer: Adding 1h 30min 10.244807s random time.
Oct 09 09:43:41 cups01.example.com systemd[1]: Reloading.
Oct 09 09:43:41 cups01.example.com systemd[1]: anacron.timer: Adding 3min 36.491068s random time.
Oct 09 09:43:41 cups01.example.com systemd[1]: apt-daily-upgrade.timer: Adding 55min 12.013554s random time.
Oct 09 09:43:41 cups01.example.com systemd[1]: apt-daily.timer: Adding 10h 29min 56.407906s random time.
Oct 09 09:43:41 cups01.example.com systemd[1]: Reloading.
Oct 09 09:43:41 cups01.example.com systemd[1]: anacron.timer: Adding 3min 8.040819s random time.
Oct 09 09:43:41 cups01.example.com systemd[1]: apt-daily-upgrade.timer: Adding 51min 42.799144s random time.
Oct 09 09:43:41 cups01.example.com systemd[1]: apt-daily.timer: Adding 8h 26min 12.266937s random time.
Oct 09 09:43:41 cups01.example.com systemd[1]: Reloading.
Oct 09 09:43:41 cups01.example.com systemd[1]: anacron.timer: Adding 14.985167s random time.
Oct 09 09:43:41 cups01.example.com systemd[1]: apt-daily-upgrade.timer: Adding 17min 16.690034s random time.
Oct 09 09:43:41 cups01.example.com systemd[1]: apt-daily.timer: Adding 29min 11.660587s random time.
Oct 09 09:43:41 cups01.example.com systemd[1]: avahi-daemon.service: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: Starting Avahi mDNS/DNS-SD Stack...
-- Subject: Unit avahi-daemon.service has begun start-up
-- Defined-By: systemd
-- Support: https://www.debian.org/support
--
-- Unit avahi-daemon.service has begun starting up.
Oct 09 09:43:41 cups01.example.com systemd[1]: user.slice: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: init.scope: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: ssh.service: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: dev-tty3.mount: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: dev-mqueue.mount: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: sys-devices-virtual-net.mount: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com avahi-daemon[1545]: Found user 'avahi' (UID 111) and group 'avahi' (GID 116).
Oct 09 09:43:41 cups01.example.com systemd[1]: ebtables.service: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com avahi-daemon[1545]: Successfully dropped root privileges.
Oct 09 09:43:41 cups01.example.com systemd[1]: systemd-tmpfiles-setup.service: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com avahi-daemon[1545]: chroot.c: fork() failed: Resource temporarily unavailable
Oct 09 09:43:41 cups01.example.com systemd[1]: systemd-sysctl.service: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com avahi-daemon[1545]: failed to start chroot() helper daemon.
Oct 09 09:43:41 cups01.example.com systemd[1]: dev-hugepages.mount: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: systemd-logind.service: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: proc-sys-net.mount: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: opensmtpd.service: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: atd.service: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: dev-tty2.mount: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: systemd-user-sessions.service: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: dbus.service: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: resolvconf.service: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: systemd-remount-fs.service: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: dev-tty4.mount: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: inetd.service: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: systemd-update-utmp.service: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: systemd-journald.service: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: proc-sysrq\x2dtrigger.mount: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: cups.service: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: cron.service: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: system-getty.slice: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: systemd-journal-flush.service: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: rsyslog.service: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: dev-tty1.mount: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: -.mount: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: console-getty.service: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: dev-ptmx.mount: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: networking.service: Failed to reset devices.list: Operation not permitted
Oct 09 09:43:41 cups01.example.com systemd[1]: avahi-daemon.service: Main process exited, code=exited, status=255/n/a
Oct 09 09:43:41 cups01.example.com systemd[1]: Failed to start Avahi mDNS/DNS-SD Stack.
-- Subject: Unit avahi-daemon.service has failed
-- Defined-By: systemd
-- Support: https://www.debian.org/support
--
-- Unit avahi-daemon.service has failed.
--
-- The result is failed.
Oct 09 09:43:41 cups01.example.com systemd[1]: avahi-daemon.service: Unit entered failed state.
Oct 09 09:43:41 cups01.example.com systemd[1]: avahi-daemon.service: Failed with result 'exit-code'.
Oct 09 09:43:41 cups01.example.com dbus[67]: [system] Reloaded configuration
Oct 09 09:43:41 cups01.example.com systemd[1]: Reloading.
Oct 09 09:43:41 cups01.example.com systemd[1]: anacron.timer: Adding 2min 3.993145s random time.
Oct 09 09:43:41 cups01.example.com systemd[1]: apt-daily-upgrade.timer: Adding 52min 20.722197s random time.
Oct 09 09:43:41 cups01.example.com systemd[1]: apt-daily.timer: Adding 3h 21min 48.068544s random time.


Please reassign, if necessary.

Regards
Harri

Simon McVittie

unread,
Oct 9, 2018, 7:10:04 AM10/9/18
to
Control: tags -1 + moreinfo

On Tue, 09 Oct 2018 at 09:55:04 +0200, Harald Dunkel wrote:
> Apparently installing libnss-mdns on Stretch in a LXC container fails with
> a catch22:

Sorry, I don't understand why you say "a catch-22". Is there a
reason why the absence of nss-mdns is preventing you from installing
avahi-daemon? From your logs, it looks to me as though the causality
all goes one way: libnss-mdns depends on avahi-daemon, and installing
avahi-daemon fails, so installing libnss-mdns also fails.

The failure to start avahi-daemon looks like #856311, which is
fixed in testing/unstable but not stretch. The root cause was that
avahi-daemon tries to lock down its environment to make it harder for
bugs (or security vulnerabilities) in avahi-daemon to cause denial of
service for the rest of the system; but it does this by reducing its
"processes per uid" rlimit, and if the same uid is already in use for
some other purpose on the host system or in another container, that
breaks avahi-daemon's assumption that its private system uid is in fact
private. In testing/unstable, the default avahi-daemon configuration
was changed to not apply special rlimits as a workaround for that.

If you are able to configure lxc to use different uid ranges for the
host system and for each container, that would avoid this bug, and also
protect other containers and your host system better.

Leaving this assigned to libnss-mdns for now because your mention of a
catch-22 makes me wonder whether there's something I'm missing.

Thanks,
smcv

Harald Dunkel

unread,
Oct 10, 2018, 8:10:04 AM10/10/18
to
Hi Simon,

I did not ask for Avahi at all. The command line was

apt install libnss-mdns

The unwanted Avahi daemon complains about missing or broken mdns
support:

Failed to start Avahi mDNS/DNS-SD Stack.

My impression was that I cannot install mdns because it relies
upon avahi, and that I cannot install avahi, because it needs
a working mdns. Catch 22.


Regards
Harri

Simon McVittie

unread,
Oct 10, 2018, 5:00:03 PM10/10/18
to
Control: tags 910637 = stretch
Control: retitle 910637 Fails to install in lxc container: fork() failed: Resource temporarily unavailable
Control: reassign 910637 avahi-daemon 0.6.32-2
Control: affects 910637 libnss-mdns

On Wed, 10 Oct 2018 at 13:56:36 +0200, Harald Dunkel wrote:
> I did not ask for Avahi at all.

Not directly, but libnss-mdns requires avahi-daemon and can't work
without it.

> The unwanted Avahi daemon complains about missing or broken mdns
> support:
>
> Failed to start Avahi mDNS/DNS-SD Stack.

Ah, I see. You're misunderstanding that message: "Avahi mDNS/DNS-SD
Stack" is just a description of avahi-daemon (Avahi is an implementation
of the mDNS and DNS-SD protocols). Avahi doesn't require libnss-mdns,
but libnss-mdns requires Avahi.

This looks like the same issue as <http://bugs.debian.org/856311> so
I'm reassigning it.

Workaround: edit /etc/avahi/avahi-daemon.conf and comment out all the
lines starting with "rlimit-".

smcv

Michael Biebl

unread,
Jun 5, 2022, 1:10:03 PM6/5/22
to
Version: 0.7-1

Should be fixed since 0.7-1

Closing accordingly.
OpenPGP_signature
0 new messages