22.11.2011 00:34, Denys Vlasenko пишет: > On Monday 21 November 2011 15:12, Alexander Varnin wrote: >> 21.11.2011 17:20, Denys Vlasenko пишет: >>> On Sun, Nov 20, 2011 at 9:22 PM, Alexander Varnin <[email protected]> wrote: >>>> I also figured out, that the only entry about init in logs is >>>> >>>> / # cat /var/log/messages | grep >>>> starting >>>> >>>> Jan 1 00:00:02 (none) daemon.info init: starting pid 53, tty >>>> '/dev/console': '/bin/sh' >>>> >>>> So this action gets read from inittab and executed. But others - not. >>> How do you know it if you /dev/null'ed stdout and stderr >>> of your sysinit actions? >> First i've tried to change null to console in inittab with no effect. >> And second i've checked the effect of commands - hostname doesn't get >> set, and fs doesn't get mounted. That all i checked in log, that was >> attached to my first message. >> >>>> And nothing even gets printed in logs, though init.c busybox file >>>> contains much calls to message(L_LOG,...) function. >>> L_LOG messages won't be logged to system log until syslogd >>> is started. Apparently it is not started soon enough (or ever) >>> to capture them. >>> >>> I also noticed that you don't reply to my suggestions. >> Sorry for that. /dev/console is in place. >> >> About this message >> >> message(L_CONSOLE | L_LOG, "init started: %s", bb_banner); >> >> I can't see it also. But I can see message in /var/log/messages, that is >> written from "run" function from init.c. > This indicates that you have a problem. > Either you don't run busybox init, or you don't have > valid stderr fd. Or both. > > One of your previous messages said: > > On Friday 18 November 2011 09:16, Alexander Varnin wrote: >> Warning: unable to open an initial console. > To which I replied: > "This is not good. Do you have /dev/console node in the root fs?" > > IOW, it indicates that at least problem #2 (you have no stderr > for your PID 1 process) is present. Kernel tries to open > stdin/stout/stderr to /dev/console before it spawns PID 1. > On your system, this fails, and kernel prints this message. > Do you have /dev/console on root fs? > > You did not reply to this, but it is important. As long as you see > "Warning: unable to open an initial console" during boot, you have > a serious problem, regardless of what init program you are using. > Concentrate on understanding and fixing *this* problem first. > Thanks! Your suggestion lead me to understanding the problem! The problem was so: i'm using udev for device nodes creation. And i've put console and null nodes to /lib/udev/devices. They appeared then in /dev, but later, than sysinit actions tried to start. Now i've moved nodes directly to /dev, and everything is ok now. Thank you for you help.
_______________________________________________ busybox mailing list [email protected] http://lists.busybox.net/mailman/listinfo/busybox
