I can no longer boot Ubuntu following a corruption problem initially reported here (How do I solve the "invalid arch dependent elf magic" error message).
When I power my laptop, I now get the following message:
GNU GRUB version 2.02~beta2-9ubuntu1.7
Minimal BASH-like line editing is supported. For the first word, TAB lists possible command completions.
Anywhere else TAB lists possible device or file completions." and then the prompt
grub>Can anyone help me get back to Ubuntu ?
33 Answers
Ok, from grub type ls (hd0,1)/
you should see a file named vmlinuz or linux, and initrd.img
Type linux (hd0,1)/vmlinuz root=/dev/sda1 or linux (hd0,1)/linux root=/dev/sda1 depending on what you found with ls (hd0,1)/, then:
initrd (hd0,1)/initrd.img
bootIf you get initramfs rescue mode enter your password, then startx.
You should now have a desktop.
Use gparted to check your file system, if it reports an error, then you need to boot from a LiveCD or other media to fix it .... DO NOT attempt to repair a mounted partition.
The following three commands fix many grub boot problems. They run quick so just do all three instead of trying to find which one you need.
sudo grub-install /dev/sda && sudo update-grub && sudo update-initramfs -uReboot and see what you get.
15The most probable cause to that issue is installing the OS to a disk, grub to a different disk that is not removable. Then removing the OS disk.
You could just plug the USB stick back in. Problem solved.
2Restart your system. Press f2 key while loading. Goto boot option. Press f5/f6 to change values (which os you want to install keep it in first place.). Enter f10 key....It may solve your problem. . . . If not enter this in grub rescue mode.... ls (hd0) (hd0,msdos6) (hd0,msdos5)....(hd0,msdos1) OR (hd0) (hd0,gpt6).....(hd0,gpt1)
set boot=(hd0,gpt6) OR set boot=(hd0,msdos6) set prefix=(hd0,gpt6)/boot/grub OR use msdos6 instead. insmod normal normal This may solve your problem.
1