bug-grub
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Missing feature?


From: Jacob Elder
Subject: Re: Missing feature?
Date: Sun, 17 Feb 2002 01:56:05 -0500
User-agent: Mutt/1.3.27i

On Sun, Feb 17, 2002 at 04:40:09PM +1000, Ron Addie wrote:
> I am sorry if this is an inappropriate destination for this msg.
> Please advise a different destination if you are unable to help.
> 
> I would like to be able to set an environmental variable from
> within my grub configuration file -- so that I can see, from
> within the boot scripts such as rc.local, which loading option
> was selected in the grub menu.
> 
> Is this possible? How can it be done?\

It's not possible to set environment varibles for arbitrary processes from
the pre-boot environment. But you can get the job done by making up kernel
command line options. For example:

title Boot from /usr/src/linux/.../bzImage
kernel (hd0,0)/usr/src/linux/arch/i386/boot/bzImage src vga=5 idebus=66

grep src /proc/cmdline >/dev/null && echo "Booted from /usr/src."

-- 
Jacob Elder
http://www.lucidpark.net/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]