From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1RxPKi-0006wu-6f for garchives@archives.gentoo.org; Tue, 14 Feb 2012 20:50:40 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 9C4E3E0A87; Tue, 14 Feb 2012 20:49:31 +0000 (UTC) Received: from mail-bk0-f53.google.com (mail-bk0-f53.google.com [209.85.214.53]) by pigeon.gentoo.org (Postfix) with ESMTP id 8E953E0B39 for ; Tue, 14 Feb 2012 20:45:03 +0000 (UTC) Received: by bkcit16 with SMTP id it16so422337bkc.40 for ; Tue, 14 Feb 2012 12:45:02 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type:content-transfer-encoding; bh=ySA0Bte7Ed83twvNp79NimPQIhpI6GPPUXWKJpGkCJI=; b=uQh9lT90lM/N9+0UmbYe92fdrMkZR/n7OmLqB9WXp+l/BV66eQCZkCTRbuV8nwTid+ drXKeRoHX/U9PmGUcdTKbFym8UqivES1dLgeQf/NJTETHboUN/pZJmlwPviaYAbMAiZU /WVKWO3q5PhFKJOw/o7G2lcNsGN3VmP3MtMRE= Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-user@lists.gentoo.org Reply-to: gentoo-user@lists.gentoo.org MIME-Version: 1.0 Received: by 10.204.152.219 with SMTP id h27mr10510736bkw.40.1329252302696; Tue, 14 Feb 2012 12:45:02 -0800 (PST) Received: by 10.205.124.129 with HTTP; Tue, 14 Feb 2012 12:45:02 -0800 (PST) In-Reply-To: <4F3AC593.4040701@trausch.us> References: <4F3A9FAA.9000504@binarywings.net> <4F3AA6C7.4050501@trausch.us> <4FEAA3B3-0A32-4347-9441-C0E3FE3E1F38@gmail.com> <4F3AAD67.9080403@trausch.us> <4F3AC593.4040701@trausch.us> Date: Tue, 14 Feb 2012 15:45:02 -0500 Message-ID: Subject: Re: [gentoo-user] grub vs grub 2 From: Michael Mol To: gentoo-user@lists.gentoo.org Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Archives-Salt: a7ad9d6f-91f9-48da-a0f2-3f0b728d2be9 X-Archives-Hash: e29dc318ade1ee4505b835bc2f899389 On Tue, Feb 14, 2012 at 3:35 PM, mike@trausch.us wrote: > On 02/14/2012 02:04 PM, Michael Mol wrote: >> A detailed elaboration would be nice. >> >> A contrasting migration guide, complete with the how's, where's and >> why's would be awesome. (Once one's invested in understanding a tool, >> a 1-2-3-itsmagic walkthrough is very discomforting.) > > While there are many different points that differ between the two, the > biggest are: > > =C2=A0- Supported upstream. > > =C2=A0- Can boot from GPT as well as MBR partition table types, regardles= s > =C2=A0 =C2=A0of whether EFI is in use or not. =C2=A0Also supports the use= of Apple > =C2=A0 =C2=A0Partition Maps, BSD disk labels, and others through modules. > > =C2=A0- Doesn't require patching to deal with modern situations; you can > =C2=A0 =C2=A0download upstream source code and it will work, unlike GRUB = Legacy. > > =C2=A0- Can boot from virtually any filesystem you would want to use, > =C2=A0 =C2=A0not just a small handful of them; includes ISO9660, UDF, Rei= ser, > =C2=A0 =C2=A0btrfs, NTFS, ZFS, HFS and HFS+, among others. > > =C2=A0- Supports selecting filesystems by UUID without distribution-speci= fic > =C2=A0 =C2=A0patches, for filesystem types that can be identified by UUID= s. > > =C2=A0- Can be booted from BIOS or EFI on the PC, and no longer depends o= n > =C2=A0 =C2=A0the existence of any particular type of firmware (no more pr= obing > =C2=A0 =C2=A0for BIOS boot drives, which can fail on many different syste= ms). > > =C2=A0 =C2=A0This means that GRUB 2 doesn't have to be hand-installed on = systems > =C2=A0 =C2=A0GRUB Legacy couldn't figure out for whatever reason. =C2=A0A= nd yes, there > =C2=A0 =C2=A0were a good number of them, where LILO was the only choice d= ue to > =C2=A0 =C2=A0its use of block maps (another not-so-robust booting mechani= sm which > =C2=A0 =C2=A0required significantly more maintenance than GRUB does). > > =C2=A0- Can boot Linux, the BSDs, any Multiboot or Multiboot2 kernel, and > =C2=A0 =C2=A0EFI applications. > > =C2=A0- Supports El Torito natively on platforms that use it (e.g., BIOS) > =C2=A0 =C2=A0to boot optical media, meaning that it is possible to use GR= UB 2 > =C2=A0 =C2=A0boot anything that can be burned to an optical disk. =C2=A0T= his makes it > =C2=A0 =C2=A0easier to work with testing environments burned to any form = of > =C2=A0 =C2=A0optical disk. > > =C2=A0- Better code quality than GRUB Legacy, with more loose coupling > =C2=A0 =C2=A0between components and making it possible for people to more= easily > =C2=A0 =C2=A0write GRUB modules than with GRUB Legacy. =C2=A0Additionally= , nearly > =C2=A0 =C2=A0anything that would have been a patch to GRUB Legacy can be = written > =C2=A0 =C2=A0as a module in GRUB 2, making it easier to share modules bet= ween > =C2=A0 =C2=A0distributions. =C2=A0This also means it is *much* more porta= ble. > > =C2=A0- Can be run as an EFI application on modern systems using EFI, suc= h > =C2=A0 =C2=A0as Intel-based Macintosh systems, without requiring BIOS emu= lation. > =C2=A0 =C2=A0It can also emulate an EFI environment for things which requ= ire it > =C2=A0 =C2=A0in order to boot. > > =C2=A0- Eliminates dependence on BIOS in order to determine available boo= t > =C2=A0 =C2=A0devices. =C2=A0This empowers GRUB to be able to boot without= firmware > =C2=A0 =C2=A0assistance from many different mediums, including USB and PX= E, even > =C2=A0 =C2=A0without firmware support. > > =C2=A0- Supports booting from Linux device-mapper and LVM2 configurations= , > =C2=A0 =C2=A0as well as encrypted partitions. > > =C2=A0- Supports kernels > 16 MB in size without patches. =C2=A0This can = happen > =C2=A0 =C2=A0when you compile a purely static kernel and support a great = deal of > =C2=A0 =C2=A0options without putting them into modules. =C2=A0Not common,= but does > =C2=A0 =C2=A0happen. > > Additionally, GRUB 2 standardizes (upstream) a number of things which > were developed independently by various distributions as patches for > GRUB Legacy. =C2=A0Gentoo's legacy GRUB is heavily patched, > > The configuration file isn't terribly difficult to figure out, either; > as I've mentioned before, there is *absolutely* no requirement to use > grub2-mkconfig, it just makes life easier. > > For example, here is the entry that boots my current kernel: > > menuentry 'GNU/Linux, with Linux 3.2.5-gentoo' --class gnu-linux --class > gnu --class os { > =C2=A0 =C2=A0 =C2=A0 =C2=A0load_video > =C2=A0 =C2=A0 =C2=A0 =C2=A0insmod gzio > =C2=A0 =C2=A0 =C2=A0 =C2=A0insmod part_gpt > =C2=A0 =C2=A0 =C2=A0 =C2=A0insmod ext2 > =C2=A0 =C2=A0 =C2=A0 =C2=A0set root=3D'(/dev/sda,gpt2)' > =C2=A0 =C2=A0 =C2=A0 =C2=A0search --no-floppy --fs-uuid --set=3Droot > 3820beff-80b5-4d05-b989-3ab9265bc2a3 > =C2=A0 =C2=A0 =C2=A0 =C2=A0echo =C2=A0 =C2=A0'Loading Linux 3.2.5-gentoo = ...' > =C2=A0 =C2=A0 =C2=A0 =C2=A0linux =C2=A0 /vmlinuz-3.2.5-gentoo root=3D/dev= /sda3 ro > > Adding an entry is no more complex as it was before; copy, paste, edit. > =C2=A0Simple. =C2=A0No commands necessary since GRUB reads the grub.cfg f= ile from > the filesystem when it loads, and doesn't embed it anywhere. > > (And yes, I have a separate /boot; reason being is that it is mounted -o > sync, that is, when it is mounted at all. =C2=A0At least on my primary > desktop system; /boot is actually on the root fs on most of my systems.) > > There will be a day when GRUB Legacy won't be supported by distributions > at all. =C2=A0There's no need to maintain multiple bootloaders (and upstr= eam > refuses to do so, reasonably), and many of the tricks, patches and > workarounds of old are no longer necessary with GRUB 2. > > Also, it becomes possible to use the Linux kernel's long-existing > installation hook to automatically update the boot list when you "make > install modules_install" a new kernel image, making kernel installation > literally a single step after the build. =C2=A0Many different distributio= ns > did this before by implementing scripts that do what grub2-mkconfig does > with GRUB 2, but for GRUB Legacy. =C2=A0Now, that's standard and upstream= so > that there isn't fragmentation. > > All told, GRUB 2 is *significantly* simpler, especially from the POV of > someone who installs, maintains and fixes systems for a living but also > from the POV of distribution packagers and maintainers. Very nice, thanks. --=20 :wq