s6-linux-init and ttys in lxc containers

From: Hoël Bézier <hoelbezier_at_leanco.fr>
Date: Tue, 8 Mar 2022 16:17:32 +0100


I’m using s6 and s6-linux-init inside lxc containers.

My /sbin/init (created with s6-linux-init-maker) contains the following:

#!/bin/execlineb -S0

s6-linux-init -c "/etc/s6-linux-init/current" -m 0022 -p "/usr/bin:/bin" -C -- "$_at_"

Right after starting my container with `lxc-start -F <container-name>`, I get
the following warning message:

s6-linux-init: warning: unable to ttyname stdout: No such device

I suspect this is due to the mechanism described on
https://github.com/lxc/lxd/issues/1724#issuecomment-194412831, although I’m not
using LXD, only lxc (which does not have a daemon running as root). Note that
s6-linux-init has been compiled against the musl libc, so the musl ttyname C
function may have the same issue as the glibc one.

That’s not a really serious issue, but I figured I’d still mention it here.


Received on Tue Mar 08 2022 - 16:17:32 CET

This archive was generated by hypermail 2.4.0 : Tue Mar 08 2022 - 16:17:46 CET