Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

This question already has an answer here:

I have Ubuntu already installed. I wanted to get windows 7 as well, I followed the instructions I was given, to partition my hard drive and to format it to a NTFS for Windows but now When I try to boot from HDD I only get Windows. I am seeing that I was (if done right) to get a GRUB menu at start you, so I may pick which one I would to start up. I would much thankful of your help, also I have no issue with having to flash my hard drive and start from scratch.

share|improve this question

marked as duplicate by Danatela, Jorge Castro, karel, mniess, psusi Jun 4 '14 at 3:07

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.

up vote 2 down vote accepted

The ideal thing would be to install Windows first then Ubuntu, allowing Grub to give you the option to choose where you want to boot. but not all is lost, you can still install Grub and it is fairly simple.

The first thing you are going to do is boot into your live Ubuntu environment (cd, flash drive).

Then you are going to install boot repair

sudo add-apt-repository ppa:yannubuntu/boot-repair
sudo apt-get update
sudo apt-get install -y boot-repair

Once you do this you will will click the first button "Recommended repair"

Once you do this you should be able to restart and remove your bootable image and Grub should be back and you should be able to boot into Windows or Ubuntu.

share|improve this answer
This is what I got after putting it in. sudo apt-get install -y bootrepair Reading package lists... Done Building dependency tree Reading state information... Done E: Unable to locate package bootrepair – VAMP BOY Jun 6 '13 at 2:53
never mind, I got it. Thank you. – VAMP BOY Jun 6 '13 at 3:31

Be aware that, in general, Windows will always overwrite the MBR or GPT equivalent. Therefore, if at all possible, the recommended method of installing another OS is to install Windows first.

Regardless, boot-repair will fix the problem. You can also set up dual boot using the Windows boot manager.

From within Windows, go to Control Panel->System->Advanced System Settings (in the left hand column)->Advanced->Startup and Recovery->Settings. In the System Startup section, use the pulldown menu to choose the default operating system to boot. You can also choose the amount of time to display the OS choice list. Hit OK and then OK again (in the previous window) to save your setup. Then, when you reboot, Windows should provide you option of booting into Windows or Ubuntu.

This, of course, assumes that Windows recognizes the Ubuntu installation.

share|improve this answer
Windows will not recognize Ubuntu, and this will not work. – TheXed Jun 6 '13 at 2:35
@Gui, As I said. Thanks! So is this Ubuntu in particular? I remember, a number of years ago, winding up in the same situation as VAMP BOY. I was using Fedora at the time, but I don't remember what version of Windows. I think it was Vista. Anyway, it DID recognize Fedora, so I was able to use the Windows Boot Manager. So is it a Ubuntu thing, or has Microsoft broken ALL Linux identification? – geo Jun 7 '13 at 4:44
Windows doesn't understand the Linux file system, and if you look at it under Disk Management, as far as Windows is concerned it is an empty partition. There is third party software that makes you able to view Linux Partitions from Windows, I don't know if this makes any difference or not, but in my experience, Windows just does not play nice with Linux. – TheXed Jun 7 '13 at 14:39
Windows doesn't need to be able to read the ext* filesystem format to boot Linux! It's simply a matter of pointing the boot manager to the correct partition, at which point it hands off to the Linux boot loader. Since it doesn't recognize the filesystem, it won't list the Linux version in its list of bootable operation systems. I got that wrong because I forgot about the filesystem issue. You have to explicitly tell it how to boot Linux and where to boot off of by giving it the disk and partition numbers, but, once done, GRUB takes over and boots whichever Linux kernel you select. – geo Jun 8 '13 at 20:13
Edit: I should have said, it used to be that Windows didn't need to recognize Linux! When I did this many years ago, all I had to do was edit the file that the Windows boot manager uses to display the list of available operating systems, à la GRUB. When the boot manager started, it would give me the list, I would choose Linux, and the Windows boot manager handed off to the Linux boot loader. But, you are right that you cannot do it using the System Control Panel, as I suggested above. For that, it would need to actually recognize the filesystem, which, as you say, it does not. – geo Jun 8 '13 at 20:19

Windows likes to overwrite the grub. You should always install Windows first and then Ubuntu. Just reinstall Ubuntu and you should be able to access both operating systems.

share|improve this answer
My friend, this is an overkill. There are several ways to restore GRUB without reinstalling Ubuntu. – Danatela Jun 2 '14 at 3:06

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