Jump to content











Photo
- - - - -

Extract the built-in menu from grldr


  • Please log in to reply
4 replies to this topic

#1 xpt

xpt

    Frequent Member

  • Advanced user
  • 135 posts
  •  
    Canada

Posted 26 September 2010 - 10:50 PM

Hi,

Sorry I can't find it any more...

How can I extract the built-in menu from grldr, make some modifications, then put it back into grldr?

Thanks

Edited by xpt, 26 September 2010 - 10:53 PM.


#2 ksanderash

ksanderash

    Frequent Member

  • Advanced user
  • 162 posts
  • Interests:electronics, PCs, cinema, reading books, psychology, philosophy
  •  
    Moldova

Posted 27 September 2010 - 01:11 AM

Posted Image

Via any hex-editor. You should search in the very end of GRLDR file for pxe detect string, then do selection from this string till the end of file, and save selection as 1.txt e.g. Then open it in any Unix text formating aware editor (Windows Notepad is not), I prefer AkelPad, edit, save, and throw file as bytes back by hex-editor.

#3 xpt

xpt

    Frequent Member

  • Advanced user
  • 135 posts
  •  
    Canada

Posted 27 September 2010 - 02:18 AM

Thanks voyajer,

In the slightest chance that someone is searching for a *nix solution, for the extraction:

$ strings grldr | sed '1,/pxe detect/{N; d}'

default 0

timeout 1

title find /menu.lst, /boot/grub/menu.lst, /grub/menu.lst

		errorcheck off

		configfile /menu.lst

		configfile /boot/grub/menu.lst

		configfile /grub/menu.lst

		find --set-root --ignore-floppies --ignore-cd /menu.lst && configfile /menu.lst

		find --set-root --ignore-floppies --ignore-cd /boot/grub/menu.lst && configfile /boot/grub/menu.lst

		find --set-root --ignore-floppies --ignore-cd /grub/menu.lst && configfile /grub/menu.lst

		errorcheck on

		commandline

title commandline

		commandline

title reboot

		reboot

title halt

		halt


#4 ded

ded

    Frequent Member

  • Developer
  • 133 posts

Posted 27 September 2010 - 09:25 AM

grubmenu.exe - It is the utility for editing of the built-in menu of grldr


Usage:
grubmenu info grldr
grubmenu print grldr
grubmenu [-r] export grldr menu.lst
grubmenu [-r] [-k] import grldr menu.lst


Download


Edited by ded, 27 September 2010 - 09:27 AM.


#5 ksanderash

ksanderash

    Frequent Member

  • Advanced user
  • 162 posts
  • Interests:electronics, PCs, cinema, reading books, psychology, philosophy
  •  
    Moldova

Posted 27 September 2010 - 11:55 AM

We don't look for royal road :thumbup:

But you are right, Ded. That's the correct way to do it :dubbio:

UPD: Bootice utility now do it too!




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users