confusing behavior with no inittab and non-tty stdin
Laurent Bercot
ska-dietlibc at skarnet.org
Thu Nov 5 10:34:21 UTC 2015
On 05/11/2015 06:33, Tycho Andersen wrote:
> I'm experiencing some confusing behavior with busybox when running it
> in an LXC container. In particular, this means that stdin, stdout, and
> stderr are all /dev/null when busybox is exec()'d as init.
The relevant function is console_init() in init/init.c in the
busybox source.
Try setting the CONSOLE environment variable to "/dev/console", or
whatever device your console is (seen from inside the container),
before executing busybox init. init will only reopen its standard
descriptors when it doesn't find such a variable.
--
Laurent
More information about the busybox
mailing list