I installed Ubuntu on a USB drive to make sure it wouldn't mess with my default windows or system just yet but...it did anyways. It ended up installing grub and moved my default windows boot to /dev/sda2. When I start my computer with the USB in, a grub menu will pop up giving me the option to boot Ubuntu (on USB) or Windows boot manager (/dev/sda2). Without the USB, a grub command line comes up and I have no idea what I'm doing there. So, how do I set /dev/sda2 to the default boot unless USB is in? I have gone through the BIOS and chose the boot order but grub was installed on my main drive and Windows got shoved to /dev/sda2. How do I set Windows back to the default boot or at least select it with grub when I start my computer without the USB?
-
Possible duplicate of Can't boot without Flash Drive plugged in – DnrDevil Feb 23 '16 at 05:48
1 Answers
It seems that your are booting in legacy mode (instead of UEFI). However, please make sure your HDD is in MBR instead of GPT when trying the followings. To know the format of your HDD, boot into either Ubuntu or Windows and check with its Disk Utility.
The reason for your issue is, during your Ubuntu installation, you installed grub on /dev/sda (your Windows HDD), but the grub files are on your USB flash drive (which is mounted as /boot
in Ubuntu). If you don't have your flash drive plugged in, grub's loader cannot find grub's files and then it fails to load the menu.
To fix it, you need to repair your MBR on your Windows HDD, and reinstall grub on your flash drive (otherwise your Ubuntu will not boot).
To repair your MBR, try any of these: (1) How to restore Windows 7 MBR without a CD; (2) How to fix the MBR for Windows 7?; (3) https://superuser.com/questions/156339/restore-win-7-mbr-without-recovery-install-disc; (4) https://superuser.com/questions/404364/fastest-way-to-restore-windows-7s-original-mbr
To re-install grub, try How to install grub on usb flash drive?
-
Ok, thanks for the links and I tried most of them but non worked. Would putting up the boot summary help? – BobserLuck Feb 24 '16 at 04:58