-1

I installed Ubuntu 12.04. I erased a GRUB file by mistake, now grub rescue doesn't let me do anything. I used Boot Repair, and now my PC is stuck at:

error: invalid arch independent ELF magic.
grub rescue>

I used Boot Repair, but it looks like my laptop can't detect my USB drive, also I can't access the BIOS.

karel
  • 114,770
Renji94
  • 1
  • 1
  • Please make an effort to communicate with us, it is hard to read. OTHERWISE : Your informations aren't lost. Even if your PC was broken, you could get them back by plugin your HDD inside another PC running Windows or Linux. I'll let others help you with your boot issue, but please edit your post to clean and rewrite it. – MrVaykadji Mar 22 '14 at 00:21
  • Sorry, I will edit it right now, Im very desesperated that every solution of this page doesnt fix my computer!!! – Renji94 Mar 22 '14 at 00:25

1 Answers1

0

If you can boot from a cd which logically you must've had to do when you installed you can download a supergrub cd which will allow you to boot into your ubuntu installation. From there just run:

sudo grub-install /dev/sda
sudo update-grub
nettux
  • 151
  • 3
  • Actually sudo command doesnt work, it says unknown command 'sudo', and i checked the dev folder and there is not a sda file – Renji94 Mar 22 '14 at 14:24