Ubuntu QA:
BlogBrainstormPackage status
Log in
Ubuntu QA
The Ubuntu community has contributed 21986 ideas, 135057 comments, 2615221 votes
Idea sandbox Idea sandbox
Popular ideas Popular ideas
Ideas in development Ideas in development
Implemented ideas Implemented ideas
Idea #1062: Grub automatically recognises OS'es (a la Supergrub)

Written by SeySayux the 29 Feb 08 at 07:32. Category: System. Related project: Nothing/Others. Status: New
Rationale
Yesterday I posted how much I hate to modify /etc/fstab, and a solution. Today I'll post about another file that I just hate to edit, namely /boot/grub/menu.lst. As I often install and remove Linux distro's (Now I actually use VM's, because I'm using a Mac) for testing them, I often have to edit /boot/grub/menu.lst. On one computer, until a few days ago I still had an old SUSE entry from 5 months ago, since I don't like editing menu.lst and I was waiting for another occasion to edit it.

A few weeks ago, I bought this Mac. Of course, I installed Ubuntu on it. In order to boot Ubuntu, a special bootloader, named rEFIt, was required. Well, I installed rEFIt (which was very easy, but after all, it's a Mac we're talking about, right?), and what suprised me was that it didn't had a menu.lst or something similar. Instead, each time it boots, it automatically detects any OS'es present and creates a nice boot menu (I mean the graphical with icons for each OS kind of nice, not the MS-DOS like text boot menu kind of nice) with all OS'es on my Mac! Well, Ubuntu could use something like that. If you read my other post (Automatically mount present filesystems), you will see that it fits exactly into the same idea. Simply tell the patched Grub to automatically add ROOTDEV=/dev/blablablah to the boot param's. Easy as what, and yet another config file eliminated.
Tags: (none)

142
votes
up equal down
Solution #1: Auto-generated solution of idea #1062
Written by SeySayux the 29 Feb 08 at 07:32.
Ubuntu Brainstorm was updated in January 2009. Since the idea #1062 was submitted before this update, its rationale and solution are not separated. Please vote accordingly, and if you have the necessary rights, please separate the rationale from the solution. Thanks!

Propose your solution

Attachments
No attachments.


Duplicates


Comments
themacmeister wrote on the 29 Feb 08 at 08:16
I believe rEFIt only works on EFI enabled machines, which means it would NOT WORK on either of my two P4 machines.

It was a good idea, just needs to be organised at the bootloader level.

grub-install does a pretty good job of auto-detecting OS'es as well :-)

Brewboy wrote on the 29 Feb 08 at 08:22
Most of the code for such a program already exists, just take a look at the "super grub" cd. it's easy to autodetect partitions and look for any potential book scripts (such as menu.lst). I think the only thing that might present a problem is multiple kernels and their parameters (runlevels). Although Ubuntu doesn't do the standard runlevels like other distros do.

SeySayux wrote on the 29 Feb 08 at 08:49
@themacmeister: I only gave rEFIt as an example. It should be easy to make something similar to it in Grub, hence SuperGrub.


@Brewboy: how about installing a small loader (a modded version of Lilo?) in the root of the Linux partition. Autogrub detects Lilo and chainloads it. Lilo would have to know on which partition it resides.

- SeySayux

Brewboy wrote on the 29 Feb 08 at 09:05
That would be most awesome... and extremely easy to implement. The need for an intelligent adaptable boot loader is a must, especially as people attempt to dual or even triple-boot. We can do better than static scripts.

Auzy wrote on the 29 Feb 08 at 12:37
Very similar to my idea which I submitted later..


http://brainstorm.ubuntu.com/idea/1190/


Mods should mark mine as dupe maybe.

SeySayux wrote on the 2 Mar 08 at 10:44
You should know that Grub is even one of the best bootloaders for Linux on that area. Lilo requires to be reinstalled each time the menu is edited.

- SeySayux

steve196 wrote on the 25 Mar 08 at 14:24
This should be optional. Eliminating config files replaces processes the user can steer with obscure processes, wher the user can just pray that they will do the right thing. I do not see, why this should be a good thing.

JhansonJr wrote on the 30 Mar 08 at 10:52
i run 2 of my computers Dual Booting with rEFIt. Even if you have an external disk with an OS on it, such as DSL, it knows there is a Linux os connected and has a picture of tux. It also recognizes the differences between Windows, FreeDOS, FreeBSD, OpenBSD, and EcomStation. Crazy awesome.

It is true that this only works on EFI machines, but I think that it would be possible to make something similar for non-EFI based systems.

Auzy wrote on the 6 May 08 at 05:27
People voting for this may consider voting for extra programming resources on Grub2 http://brainstorm.ubuntu.com/idea/8143/

Grub2 has a lot of cool features, and is more extendible, to maybe do a supergrub/rEFIt like thing


Post your comment