Hi! sorry for taking so long to respond.
My starting point was a working grub-pc (squeeze, amd64) setup. I then installed grub-efi version 1.99-26 (wheezy, amd64) via aptitude/synaptic so grub-pc probably was uninstalled but not purged (it is purged now). I used hints gleaned from bug report #623297 to avoid pitfalls. On Mon, Jan 28, 2013 at 11:58:00AM +0000, Colin Watson wrote: > On Sat, Jan 26, 2013 at 05:56:02PM +0100, Jens G wrote: > > After successfully installing Grub to the ESP and getting the UEFI to run > > grubx64.efi Grub (after welcomming me) complained: > > > > | error: invalid arch independent ELF magic. > > | grub rescue> As I wrote in my original bug report: |at this prompt I could list the available partitions but I |couldn't access their content via "ls (hdx,gpty)". Commands |other than "ls" weren't accessible either, Therefor, I assume that grubx64.efi was unable to find or load it's modules. I checked the *.mod files from the grub-pc AMD64 and grub-efi* AMD64 packages: 'file' reports grub-pc's are 32bit ELF binaries while grub-efi's are 64bit binaries. Taking grubx64.efi's error message into account I theorize that it was finding and trying to use grub-pc's 32bit modules and failed, resulting in an absolutly bare rescue shell. Bug report #680718 seems to be about a similar or identical problem with regard to the *.mod files > This probably means that it's trying to load modules from /boot/grub/ > and they're actually for grub-pc rather than grub-efi-amd64. What is > $prefix set to? (You can inspect it in the rescue shell using 'set'.) Then | I installed Grub under a second label and added --modules="part_gpt ext2" with two consequences: 1. Both grubx64.efi binaries have the same size but different MD5sums. 2. IIRC the 1st grubx64.efi suddenly worked (I switched to the 2nd now) This looks like grub-install does not move *.mod and/or other files to their right place at least some of the time. Maybe the --modules option forces an overwrite of existing files because you wrote > I doubt this was necessary. grub-install autodetects the > necessary modules already, In my quest to get this to work I relied heavily on <https://wiki.archlinux.org/index.php/GRUB2> and guessed educatedly which command line options exist/to use in this version. Unless newer packages work differently it would be very helpful to include a small README with a list of low level commands to build necesary files and move files to the right places manually. This old Grub 1.x way to install by hand was cumbersome but would provide a safety net until an automated install works reliably. Cheers Jens p.s. No news on > > This happend when running grubx64.efi from an EFI-shell (v1) and with the > > normal UEFI boot sequence. However, when I used the previously installed > > rEFInd boot manager to launch grubx64.efi, Grub worked just fine. > > That's a little mysterious. I may contact Rod Smith, the author of rEFInd. BTW he has some IMHO helpful documentation on UEFI/Linux as well at <http://www.rodsbooks.com/efi-bootloaders/> -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org