Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

Possible Duplicate:
GRUB: “invalid arch independent ELF magic” after install on SSD

I am currently trying at get an dual boot computer work, where the Ubuntu 12.04 system is spread over two drives.

The setup of the two drives are:

HDD

/dev/sda1 /boot/efi

/dev/sda2 some unknown msftres at 128MB (dont bother about this as long as the rest works)

/dev/sda3 windows7

/dev/sda4 /home

/dev/sda5 swap

/dev/sda6 /tmp

/dev/sda7 /var


SSD

/dev/sdb1 /

In an attempt to combine speed with SDD survival. Now, that might be a topic in itself, but for now I would be very happy just to get the Grub bootloader to work.

When booting at either HDD or SSD, I get: error: invalid arch independent ELF magic. grub rescue>

Very grateful for all kinds of suggestions for how to solve this!

share|improve this question
    
Unlike the above, where / and /boot were on separate partitions, yours is all on /dev/sdb1, is that correct? Are you booting from the hard disk or from the SSD? –  John S Gruber Oct 14 '12 at 15:31
add comment

marked as duplicate by jokerdino, devav2, Jorge Castro, Ringtail, Anwar Shah Oct 15 '12 at 6:00

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

2 Answers

I had the same problem “invalid arch independent ELF magic”.

I was installing from a USB stick booted from the Bios in UEFI mode.

After a couple a couple unsuccessful reinstallation of 12.04,I tried the same installation with the the USB stick booted without the UEFI mode and it works.

For your information my setting on a 120GB SSD

sda1 /windows 90 GB windows 7 64bits

sda2 /boot 100 MB

sda5 swap 1 GB

sda6 / 18GB ubuntu 12.04

sda7 /home 8GB

My motherboard is P8P67 Pro with Asus EZbios and I had two choices in my boot menu for the USB with 12.04 installation.

Hope it helps!

share|improve this answer
    
Fixed the elf arch magic problem for me. The installer then failed with migration assistant but that's separate. –  kikixx May 6 '12 at 13:40
add comment

I have fixed the same problem with Backtrack on VMware the boot was broken after installing vmware tools.

I used the following commands :

sudo mount /dev/sda1 /mnt

then

sudo grub-install --root-directory=/mnt /dev/sda
share|improve this answer
add comment

Not the answer you're looking for? Browse other questions tagged or ask your own question.