Norman,

You'd need to modify the /linuxrc script in the initrd image to pass
the runlevel from the commandline on to the /sbin/init program.

Or, another method would be to pass an argument on the kernel command 
line,  maybe something descriptive like 'FIXWIN=Y'.

This would get passed as an environment variable to the rc.sysinit 
script, which could then be modified to look for $FIXWIN and see if it
equals 'Y'.  If it does, invoke your fix_windows script.  That wouldn't
require a change to inittab.

Jim McQuillan
[EMAIL PROTECTED]




On Thu, 8 Jan 2004, Norman Gaywood wrote:

> I'm using ltsp4.
> 
> How do you pass a run level to init when booting a ltsp kernel?
> 
> Here is my setup:
> 
>    1. Workstation uses dhcp and tftp to boot nbgrub.
> 
>    2. nbgrub provides a menu with choices:
>                Linux Terminal (ltsp)
>                windows on local disk
> 
> The nbgrub entry for the linux terminal looks like:
> 
> title Linux Terminal (ltsp)
>    root (nd)
>    kernel /lts/2.4.22-ltsp-2/bzImage-2.4.22-ltsp-2 init=/linuxrc rw root=/dev/ram0
>    initrd /lts/2.4.22-ltsp-2/initrd-2.4.22-ltsp-2.gz
> 
> That works great, I can boot ltsp or the local disk.
> 
> But, the other thing I want to do is have another entry in the grub
> menu. Say: "Fix broken windows partition". This should boot ltsp but not
> start the X server. It should start something like this from inittab:
> 
> dr:4:wait:/etc/rc.diskrefresh
> 
> rc.diskrefresh should copy images to the local disk and then reboot
> the client.
> 
> But to do that, I need a runlevel 4. I have not been able to do that. I
> thought:
> 
>  kernel /lts/2.4.22-ltsp-2/bzImage-2.4.22-ltsp-2 init=/linuxrc rw root=/dev/ram0 4
> 
> would do it but the client always goes to runlevel 5
> 
> Any ideas? Am I doing this all wrong?
> 
> Cheers.
> 
> 



-------------------------------------------------------
This SF.net email is sponsored by: Perforce Software.
Perforce is the Fast Software Configuration Management System offering
advanced branching capabilities and atomic changes on 50+ platforms.
Free Eval! http://www.perforce.com/perforce/loadprog.html
_____________________________________________________________________
Ltsp-discuss mailing list.   To un-subscribe, or change prefs, goto:
      https://lists.sourceforge.net/lists/listinfo/ltsp-discuss
For additional LTSP help,   try #ltsp channel on irc.freenode.net

Reply via email to