avoid kernel messages at boottime

April 13, 2011

[Warning: This post is a backup recovery from my previous Wordpress blog. All content was automatically converted accessing a MySQL database using a Python script (details). Mostly are in Portuguese but if you are interest I can translate to English. If you found any problem dont’t hesitate to contact me in comments.]

Linux embedded normally don't behave as the same in desktop system, maybe instead login at your device you need only run a specific application - for example - by just modifying an start script. Although easily... one requisite that I faced these days was avoid boot messages from kernel, accomplished by changing kernel parameters:

setenv bootargs 'console=none root=/dev/mmcblk0pX rootwait init=/sbin/init'

But this parameter broke the output of my start code (a shell script) located on /etc/rc.d/…

Checking for solutions I go back to getty and added two parameters "-l" and "-n" to specify your program (or script) and prompt for nologin.

$ cat /etc/inittab

::sysinit:/etc/rc.d/rcS ::respawn:/sbin/getty -L ttymxc0 115200 vt100 -l /path/to/your/program -n ::ctrlaltdel:/sbin/reboot ::shutdown:/etc/rc.d/rcS stop ::restart:/sbin/init

Now I can see the serial output without kernel boot messages.