[buug] different runlevel with a headless box
Brian Dessent
brian at dessent.net
Sun Oct 21 17:58:53 PDT 2007
Ian Zimmerman wrote:
> Can anyone think of a way to do this? I don't mean "how to create a
> runlevel to make a box headless", rather how to have two different
> runlevels on a box that is already headless and choose between them when
> booting. I am thinking along the lines of attaching some sort of dongle
> (USB pen drive maybe), but how to make grub (or later init) react to
> that?
I can't find it in the docs right now, but I seem to recall that you can
specify a desired runlevel to init with a single digit in the kernel
command line, eg:
title Foobar GNU/Linux, kernel x.y.z-foo (headless)
kernel /vmlinuz-x.y.z-foo root=/dev/<whatever> ro 2
title Foobar GNU/Linux, kernel x.y.z-foo (X11)
kernel /vmlinuz-x.y.z-foo root=/dev/<whatever> ro 5
Failing that, according to inittab(5) if there is no runlevel marked
initdefault, then init will prompt on the console for a runlevel at boot
time.
Brian
More information about the buug
mailing list