inittab question

David A. Bandel david
Mon May 17 11:34:36 PDT 2004


On Mon, 8 Jul 2002 15:50:34 -0400
begin  Matthew Carpenter <matt at e-i-s.cc> spewed forth:

> Are you serious?  IIRC, the initial field is a unique identifier,
> nothing else.  Are you telling me that if you stick a number there 1-12
> it will stick the output to that screen?

No.

> 
> 
> 
> On Mon, 8 Jul 2002 09:22:40 -0400
> "Douglas J Hunley" <doug at hunley.homeip.net> wrote:
> 
> > -----BEGIN PGP SIGNED MESSAGE-----
> > Hash: SHA1
> > 
> > Would the following code in /etc/inittab would?
> > 
> > 11:2345:boot:/usr/bin/tail -f /var/log/mesages|/some/program
> > 12:2345:boot:/usr/bin/top

No.  It would have to be something like:

11:2345:respawn:/usr/bin/tail -f /var/log/messages|/some/program >
/dev/tty11 2>/dev/null

But there's an extra problem here.  The /some/program can't be just any
program.  It also can't be /usr/bin/tail.  Whatever is going to write to
/dev/tty11 via inittab must not require a controlling terminal.  Some code
does.  tail is an example.  You have to run tail from a terminal, you
can't run it and redirect it's output in inittab.  Won't work.

> > 
> > this would give us 'top' on tty12, and the output of a log parser on
> > tty11. no?

No.

Ciao,

David A. Bandel
-- 
Focus on the dream, not the competition.
		-- Nemesis Racing Team motto



More information about the Linux-users mailing list