On Fri, Jun 29, 2012 at 2:38 PM, Rich Freeman <ri...@gentoo.org> wrote: > On Fri, Jun 29, 2012 at 2:29 PM, Mike Gilbert <flop...@gentoo.org> wrote: >> It does copy all of the images to /boot so that the grub shell can be >> used to install an MBR image. grub:2 no longer has an interactive >> shell and grub2-install must be used. Therefore, copying files to >> /boot in the ebuild is completely pointless. > > Does grub2-install place any stage files where they need to be, or are > they no longer needed? I haven't experimented with it yet. > > Normally grub1 needs to be able to find the stage2 file, and that has > to be on a partition the stage1.5 can read (I believe stage1.5 is in > the diagnostic cylinder - it only uses the files in /boot during > installation).
grub2 eliminates the stage_1_5 files. Instead, a "core" image is built by grub2-install. Here's how it works. 1. grub2-install copies all grub modules to /boot/grub2. This can be any file system readable by GRUB. 2. grub2-install calls grub2-mkimage which combines any modules necessary to access /boot into core.img. 3. grub2-install calls grub2-bios-setup which installs boot.img into the MBR and embeds core.img into the sectors immediately after the MBR. > > I'm not sure if grub2 completely eliminates the need to have a > "normal" partition somewhere, in a situation where raid+lvm+etc are > used. You do need a filesystem that grub2 can access through some combination of modules, and an area in which to embed core.img. The grub2 manual has a pretty good explanation. http://www.gnu.org/software/grub/manual/html_node/Installing-GRUB-using-grub_002dinstall.html http://www.gnu.org/software/grub/manual/html_node/BIOS-installation.html http://www.gnu.org/software/grub/manual/html_node/Images.html