Modifying init to create /dev/console ?

Robert Schwebel robert at schwebel.de
Tue Mar 13 01:00:27 PDT 2007


On Sun, Mar 11, 2007 at 11:06:14PM +0100, Robert Schwebel wrote:
> ----------8<----------
> #!/bin/sh
> 
> mount -t tmpfs none /dev -o mode=755
> 
> mknod /dev/console c 5 1
> chmod 600 /dev/console
> mknod /dev/null c 1 3
> chmod 666 /dev/null
> 
> exec /bin/busybox init $@ 1> /dev/console 2> /dev/console < /dev/console
> ----------8<----------
> 
> but still get:
> 
> VFS: Mounted root (nfs filesystem).
> Freeing init memory: 88K
> Warning: unable to open an initial console.
> init started:  BusyBox v1.1.3 (2007.03.11-10:31+0000) multi-call binary
> 
> Does anybody have an idea how to get rid of the warning?

Ah, and a regression: you don't get kernel messages any more on that
console, because although init has a console now, the kernel does not.

Robert 
-- 
 Dipl.-Ing. Robert Schwebel | http://www.pengutronix.de
 Pengutronix - Linux Solutions for Science and Industry
   Handelsregister:  Amtsgericht Hildesheim, HRA 2686
     Hannoversche Str. 2, 31134 Hildesheim, Germany
   Phone: +49-5121-206917-0 |  Fax: +49-5121-206917-9



More information about the busybox mailing list