/etc/inittab : not specifying baud rate and tty device

Rich Felker dalias at aerifal.cx
Wed Aug 2 16:04:51 UTC 2006


On Wed, Aug 02, 2006 at 01:56:56PM +0100, Stuart Hughes wrote:
> 
> Like most people I'm booting linux on my embedded boards connected to a
> serial port and using busybox's init.
> 
> One thing that is always a bit annoying is having to know the tty device
> and baud rate of the serial port, especially given that it's already
> setup by the kernel.  So in the past I've had a variety of entries
> in /etc/inittab for different boards, for example:
> 
> ::respawn:/sbin/getty -L ttyS0 115200 vt100
> ::respawn:/sbin/getty -L ttyS0 38400 vt100
> ::respawn:/sbin/getty -L ttyS1 115200 vt100
> ::respawn:/sbin/getty -L ttyCPM0 38400 vt100
> 
> The first thing that is not constant is the serial tty device.  To make
> this generic I tried 'console' instead, which seems to work.  Does this
> sound like a reasonable thing to do?

No. /dev/console is incapable of acting as a controlling terminal and
thus any shells starting on it will not be able to perform job
control.

Rich




More information about the busybox mailing list