Jump to content











Photo
- - - - -

Need help converting grub to grub 2 and grub4dos


  • Please log in to reply
1 reply to this topic

#1 abispac

abispac
  • Members
  • 2 posts
  •  
    United States

Posted 16 October 2017 - 08:16 PM

Hello, thanks for reading, im currently building a triple boot computer with Recalbox,windows10 and ubuntu. I built a similar computer in the past with no problem, but instead of using recalbox i was using wifislax, so the way i did was, i started with wifislax to partition the hardrive, with space for the 3 systems, installed wifislax first , then windows, and at the end ubuntu, so tis would make ubuntu detect the first 2 systems and created the correct grub file or whatever it does, so i ended with a perfect 3 systems computer. I was trying to do the same, problem is ubuntu detectes the systems that are installed and creates a menu but only with windows and ubuntu only, it ignores the first os wich is recalbox. 

On the first partition wich is for recalbox, i have a fat32 BOOT , a second one named RECALBOX wich is ext4 and cotains the file system, and a 3rd one wich is the share partition. On the first partition, BOOT there are 2 folders, one called boot and another called efi , on the boot one there are  1 folder and 2 files, the grub folder, and bzImage and initrd, and on the efi folder theres another boot folder with a bootx64.efi and a grub file, this is the content of the grub file.

set default="0"
set timeout="0"


menuentry "Recalbox" {
linux /boot/bzImage label=RECALBOX console=tty3 quiet loglevel=0
initrd /boot/initrd.gz
}

So i wonder if someone can help me out to convert this over to grub2 so i can modifyit before i install ubuntu, that way ubuntu will recogniseit, and if is posible to convert also to grub4dos so i can use it with other setup in the future. 

 

Thanks in advance for any help.

 



#2 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 13749 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 4 weeks ago

That s already GRUB2 (what the good grub guys now call GRUB having decided to rename the real GRUB as GRUB LEGACY).

 

What is biting you is the (overcomplex BTW and severely under-documented) way GRUB2 autocreates menues.

 

In GRUB (the real thing now senselessly called GRUB LEGACY) that would be:



title Recalbox
kernel /boot/bzImage label=RECALBOX console=tty3 quiet loglevel=0
initrd /boot/initrd.gz

And grub4dos would be exactly the same.

 

This entry assumes that the root is already established on the volume where /boot/bzImage and /boot/intrd.gz are, otherwise you will need to either establish a "hardcoded" root, such as "root (hd0,0)" or use someting like "find --set-root /boot/bzImage" before the kernel line. 

 

If you want to modify the mechanism of autogeneration of grub.cfg, see here:

https://www.dedoimed...ers/grub-2.html

https://www.dedoimed...#mozTocId226706

https://www.dedoimed...#mozTocId293325

 

You normally want to modify the  40_custom file adding the other "static" entries (such as the one you posted).

 

:duff:

Wonko






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users