julian.simioni at gmail
Mar 23, 2012, 11:36 AM
Post #3 of 3
That's an excellent utility, I'll definitely add it to my toolbox, thanks.
I actually was able to solve my problem myself: shortly after posting I
found a post by renergy on the forums:
It looks like the magic parameters to grub2-install are --root-directory
and --boot-directory. Annoyingly, --root-directory is not listed in the
help output or man page, so I had no easy way of knowing it existed. But at
least everything works now.
On Thu, Mar 22, 2012 at 3:32 PM, Maxim Wexler <maxim.wexler [at] gmail>wrote:
> Here's a marvelous program crying out for an ebuild;
> It's part of my Ubuntu setup. With one click it goes out and finds all
> the boot partitions on your hd(s) and automatically writes the proper
> grub2 configuration for them. It even pastebins a copy of grub.cfg
> for troubleshooting purposes, though I have never needed it, sof far.
> When you boot all your OSes are there in the menu ready to be
> selected. In my case Ubuntu, Gentoo and Sabayon. .
> On 3/21/12, Julian Simioni <julian.simioni [at] gmail> wrote:
> > Hi all,
> > I'm working on the exciting and challenging task of installing Gentoo
> > on a new Macbook Pro with grub2 and EFI. I've got things booting, but
> > every time grub complains of many missing commands including search,
> > echo, and most surprisingly '['. It also can't find any modules, and
> > in order to get everything to work I had to specify about 10 modules
> > to be built in using grub2-mkimage. This feels a little suboptimal to
> > me, but I can't figure out where various things need to be for grub to
> > find them happily.
> > My partition layout at least is simple since I don't plan on dual
> > /dev/sda1: big root partition using ext4
> > /dev/sda2: 200MB vfat EFI partition, set to bootable (yes this should
> > be sda1: I didn't know you needed an EFI partition until after I had
> > already made the root partition and started installing things. I was
> > able to add this partition later with gparted)
> > Of course I'm using GPT, not MBR.
> > On /dev/sda2 I've got the grub2 image at /EFI/BOOT/BOOTX64.EFI as is
> > standard, and I have been mounting /dev/sda2 at /boot/efi. I can put
> > either a grub2 image or a 3.3 kernel with EFI stub support at
> > /EFI/BOOT/BOOTX64.EFI and it gets detected just fine, so I'm on the
> > right track.
> > I've tried messing with various permutations of the -p parameter to
> > grub2-mkimage, but haven't gotten anywhere. Right now the *.mod and
> > *.lst files from /usr/lib/grub/x86_64-efi/ can be found at both
> > /boot/grub2/x86_64-efi and /boot/efi/EFI/BOOT/. Where is it that they
> > actually should be?
> > Thanks,
> > Julian