Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.
   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1          13      102400    7  HPFS/NTFS   - system restore
/dev/sda2              13        4674    37436416    7  HPFS/NTFS  - Windows 7
/dev/sda3            4674       58843   435116032    7  HPFS/NTFS -  data storage
/dev/sda4           58843       60802    15728640   83  Linux - Ubuntu 10.10

Initially I installed StartUpManager. This ( I think ) added another 4 instances of Linux + memtest to my boot menu list. However, I did not see the GRUB boot menu. The computer boots into Ubuntu after a few seconds.

I have tried to add windows 7, but I did not succeed.

This is a part of my menu.lst file.

title        Ubuntu 10.10, kernel 2.6.35-24-generic
uuid        1c9748e2-2f11-4a6c-91c0-7310d48c4a7a
kernel        /boot/vmlinuz-2.6.35-24-generic root=UUID=1c9748e2-2f11-4a6c-91c0-7310d48c4a7a ro quiet splash
initrd        /boot/initrd.img-2.6.35-24-generic


title        Chainload into GRUB 2
root        1c9748e2-2f11-4a6c-91c0-7310d48c4a7a
kernel        /boot/grub/core.img

title        Ubuntu 10.10, memtest86+
uuid        1c9748e2-2f11-4a6c-91c0-7310d48c4a7a
kernel        /boot/memtest86+.bin


menuentry “Windows 7″ {
set root=(hd0,2)
chainloader +1
}

And this is after upgrade-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-2.6.35-24-generic
Found kernel: /boot/vmlinuz-2.6.35-22-generic
Found GRUB 2: /boot/grub/core.img
Found kernel: /boot/memtest86+.bin
Updating /boot/grub/menu.lst ... done

Later Edit:

I have added the following to /etc/grub.d/40_custom and I have uncommented the hidden menu line from menu.lst, but I still cant see any boot menu. I have also tried to press ESC and SHIFT.

menuentry "Windows 7 (loader) (on /dev/sda1)" {
  insmod part_msdos
  insmod ntfs
  set root='(hd0,msdos1)'
  chainloader +1
}

menuentry "Windows 7 (loader) (on /dev/sda1)" {
  insmod part_msdos
  insmod ntfs
  set root='(hd0,msdos0)'
  chainloader +1    
}

menuentry "Windows 7 (loader) (on /dev/sda1)" {
  set root= hd(0,0)
  chainloader +1
}

menuentry "!Windows 7 (loader) (on /dev/sda1)" {
  set root= hd(0,1)
  chainloader +1
}

menuentry "!!Windows 7 (loader) (on /dev/sda1)" {    
  set root= hd(0,2)
  chainloader +1
}
share|improve this question
1  
Just try sudo update-grub –  karthick87 Apr 22 '11 at 7:32

2 Answers 2

This is My windows 7 loader:

menuentry "Windows 7 (loader) (on /dev/sda1)" {
insmod part_msdos
insmod ntfs
set root='(hd0,msdos1)'
chainloader +1
}

This should work If you copy and paste it, but I dont think you should put it in your menu.lst file. It should go in /etc/grub.d/40_custom

share|improve this answer

Yo have to know your Windows 7 parition. (for me "hd0, msdos2").. You can use;

menuentry 'Windows 7 (loader) (on /dev/sda2)' --class windows --class os
$menuentry_id_option 'osprober-chain-9A4600EC4600CB49' {
    insmod part_msdos
    insmod ntfs
    set root='hd0,msdos2'
    if [ x$feature_platform_search_hint = xy ]; then
      search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos2 --hint-efi=hd0,msdos2 --hint-baremetal=ahci0,msdos2  9A4600EC4600CB49
      else
      search --no-floppy --fs-uuid --set=root 9A4600EC4600CB49
      fi
      ntldr ($root)/bootmgr # <--- change this
}

Or You can use;

menuentry 'Windows 7 (loader1) (on /dev/sda2)' --class windows --class os
$menuentry_id_option 'osprober-chain-9A4600EC4600CB49' {
    insmod part_msdos
    insmod ntfs
    set root='hd0,msdos2'
    if [ x$feature_platform_search_hint = xy ]; then
      search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos2 --hint-efi=hd0,msdos2 --hint-baremetal=ahci0,msdos2  9A4600EC4600CB49
      else
      search --no-floppy --fs-uuid --set=root 9A4600EC4600CB49
      fi
      ntldr /bootmgr  # <--- change this
}

Or you have to open bash..

sudo update-grub2

vi grub.cfg

** change the lines I have marked with ** # <--- change this** in your grub.cfg. and then..

sudo grub-install /dev/sda

that's it..

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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