Where is grub-set-default?


Forum: HD Install
Topic: Where is grub-set-default?
started by: khurdp

Posted by khurdp on Oct. 20 2005,13:13
Hello,
 I am trying to setup grub such that it can boot from a fallback entry. When booting, grub does a 'savedefault' but I don't see the default directory mentioned in the manual besides there isn't a grub-set-default that I was planning to put in opt/bootlocal.sh.

 I was wondering if grub.dsl (0.95) would have what I need or am I missing something or should I be doing something different.

Thank you,
Prasad

Re: < http://www.gnu.org/softwar....systems >

Posted by doobit on Oct. 20 2005,14:42
Those entrys go in the menu.lst file of the /boot/grub directory
Posted by khurdp on Oct. 20 2005,15:38
I do have the entries per the manual in the menu.lst file in the /boot/grub directory.

My menu.lst is something like this
----------------------------------------------
default saved
timeout 10
fallback 1

title A
....
....
savedefault fallback

title B
....
...
savedefault
-----------------------------------------------------

Per the above menu.lst file, the first time boot saves the default as 1 so the next time, title B will boot and it will keep booting B till the default is changed to 0. So, everytime the system is booted without any errors or problem, the grub-set-default 0 needs to be executed. the fallback 'B' will boot only if grub-set-default is not executed when an error occurs.

from Grub
1) the savedefault is not saved
from DSL
2) the grub-set-default is not present just in case the default file is hidden somewhere.

-Prasad

Posted by doobit on Oct. 20 2005,18:24
Maybe I'm not understandng what you are saying, but in DSL, any change in scripting gets written into the backup.tar.gz file. If you put it in filetool.lst, for example, the new version gets packed into that backup file.
Posted by khurdp on Oct. 20 2005,18:47
Sorry for not expressing myself correctly doobit. I have corrected(edited) myself in my last post.

from Grub
1) the savedefault is not saved
from DSL
2) the grub-set-default is not present just in case the default file is hidden somewhere.


From the Grub changelog, it looks like grub versions after 06-20-04 have grub-set-default which actually creates the default file and which it is advised should be modified by it only.

thank you,
Prasad

Posted by khurdp on Oct. 22 2005,22:38
Well this is how I accomplised 'Booting fallback systems':

On my Fedora core 2 system:
 I downloaded grub-0.97.tar.gz from < http://www.gnu.org/software/grub/, > unzipped, untarred and followed the INSTALL - compile and make to have the 0.97 version compiled in the current directory. Used the newly compiled grub ( ./grub ) to install on my DSL harddisk(physically removed) connected via USB.

 Booting from the newly installed grub didn't work because I didn't copy the stage1, stage2 & e2fs_stage1_5 over to the /boot/grub folder (I had to manually do this since I didn't do a grub-install). I also copied the grub-set-default script from the utils folder so my DSL now uses grub 0.97 to boot with 'savedefault', 'fallback', default saved' working per the manual and the 'grub-set-default' sets the default to 0 from opt/bootlocal.sh too.

I need the fallback because this computer I have DSL installed (frugal) doesn't have a monitor, keyboard or mouse. I ssh & vnc into it. if i screw up something I can ssh into it and maybe fix it. I can mount its harddisk via USB on my other machine but that is a hassle.

-Prasad

Posted by cbagger01 on Oct. 23 2005,07:47
removed by author
Powered by Ikonboard 3.1.2a
Ikonboard © 2001 Jarvis Entertainment Group, Inc.