-1

I have Ubuntu 14.04 installed on an SSS running perfectly. Got a new 2TB drive that has Windows 7 installed on it.

How do I add Windows 7 to my grub menu?

This is output of sudo update-grub:

Searching for GRUB installation directory ... 
found: /boot/grub Searching for default file ... 
found: /boot/grub/default Testing for an existing GRUB menu.lst file ... 
found: /boot/grub/menu.lst Searching for splash image ... 
none found, skipping ... 
Found kernel: /boot/vmlinuz-3.13.0-51-generic 
Found kernel: /boot/vmlinuz-3.13.0-49-generic Found kernel: /boot/vmlinuz-3.13.0-24-generic 
Found kernel: /boot/memtest86+.bin Updating /boot/grub/menu.lst ... done

This is the output of sudo os-prober:

sudo os-prober /dev/sdc1:Windows 7 (loader):Windows:chain
Tim
  • 32,861
  • 27
  • 118
  • 178
Darby Gallagher
  • 89
  • 1
  • 1
  • 6
  • you will need a new product key if the mobo is not the one originally registered to windows 7 unless w7 was purchased separately and then in some cases it may be licensed to more than one computer. – mchid May 04 '15 at 21:23
  • "can I not just manually tell it to add windows?" answered here: http://askubuntu.com/a/22632/40581 – LiveWireBT May 05 '15 at 07:41
  • Is /dev/sdc1 in the /etc/fstab ? If not, add it, but with a noauto flag. – s3lph May 08 '15 at 13:59
  • @mchid How is that in any way related to the OPs question? Even an unactivated Windows can be booted. – s3lph May 08 '15 at 14:00
  • @the_Seppi While it is in no way an answer or a solution to the question, it is closely related. Microsoft defines "new computer" as a different mobo in the licensing agreement. – mchid May 08 '15 at 18:14

1 Answers1

2

Run the command sudo update-grub.

If it still does not work try boot-repair. It will attempt to fix the problem, if it can't it will provide a link with all the information we need to further troubleshoot the issue.

Pabi
  • 7,401
  • 3
  • 40
  • 49
  • did that. still nothing. – Darby Gallagher May 04 '15 at 20:40
  • 1
    Make sure os-prober is installed with sudo apt-get install os-prober. – Pabi May 04 '15 at 20:44
  • said that the latest version of os-prober already installed. – Darby Gallagher May 04 '15 at 20:47
  • can I not just manually tell it to add windows? – Darby Gallagher May 04 '15 at 20:48
  • That is what update-grub does. Can you edit your question with the output of sudo update-grub. – Pabi May 04 '15 at 20:50
  • this is output of sudo update-grub: Searching for GRUB installation directory ... found: /boot/grub Searching for default file ... found: /boot/grub/default Testing for an existing GRUB menu.lst file ... found: /boot/grub/menu.lst Searching for splash image ... none found, skipping ... Found kernel: /boot/vmlinuz-3.13.0-51-generic Found kernel: /boot/vmlinuz-3.13.0-49-generic Found kernel: /boot/vmlinuz-3.13.0-24-generic Found kernel: /boot/memtest86+.bin Updating /boot/grub/menu.lst ... done – Darby Gallagher May 04 '15 at 20:53
  • this is output of sudo os-prober: sudo os-prober /dev/sdc1:Windows 7 (loader):Windows:chain – Darby Gallagher May 04 '15 at 20:54
  • You should edit that in you question please, not post it as a comment. – Pabi May 04 '15 at 20:54
  • @Pabi he's edited it in. – Tim May 04 '15 at 21:16
  • @DarbyGallagher I believe this can happen when windows is not shut down properly. You can run Gparted to find out. Open gparted and select the device /dev/sdc1 and see what is says. If there is an exclamation icon to indicate an error, click on it to receive relevant information. – mchid May 04 '15 at 21:21
  • I persume it was never booted, as it is a new drive and not in GRUB. – Pabi May 04 '15 at 21:23
  • @Pabi you can buy a new hard drive with windows already installed? – mchid May 04 '15 at 21:25
  • Thats what he stated in his question... – Pabi May 04 '15 at 21:27
  • It has never been booted. I ran gparted. I didn't see and exlamation icon. I thought it would be as simple as editing the grub file and simply telling it where to look. I keep trying to have a linux installation but have to give up because I can't get something to work. I believe in linux, but it just doesn't want to work for me. – Darby Gallagher May 04 '15 at 21:27
  • @DarbyGallagher I believe your issue is getting windows to work and not linux. have you tried to run sudo update grub again or did you just run it once and give up? – mchid May 04 '15 at 21:28
  • As stated in my answer, please try boot-repair. It may be able solve the problem, if not will provide the information we need. – Pabi May 04 '15 at 21:30
  • @DarbyGallagher as a test, disconnect the Ubuntu drive and only have the windows drive connected. Boot up the computer and see why windows isn't working. I suspect your problem is there if update grub does not work – mchid May 04 '15 at 21:31
  • I have run sudo update grub numerous times. I have the most perfect install of Linux I have ever had since I started with it with Red Hat 2.0. The problem is, if I can't have windows running for my kids, it doesn't matter how great linux is for me. – Darby Gallagher May 04 '15 at 21:31
  • I will try rebooting without linux drive attached before I wipe the linux drive. – Darby Gallagher May 04 '15 at 21:31
  • 1
    I do not talk about update-grub. I am talking about boot-repair which is linked in my answer. – Pabi May 04 '15 at 21:32
  • 1
    @Pabi address your comment with @ + DarbyGallagher at the beginning so that he will receive a notification for it. – mchid May 04 '15 at 21:37
  • No boot-repair in ubuntu software, and I won't remember the commands if I boot from live-cd. Says no match for boot-repair. – Darby Gallagher May 04 '15 at 21:38
  • If you follow the link and read the few lines there is all the informations you need on how to install or run it from a live media. – Pabi May 04 '15 at 21:40
  • He will get the notification anyway because it is his question. – Pabi May 04 '15 at 21:40