PDA

View Full Version : [ubuntu] Re-installed 10.4 but win7 has disapeared from Grub



confused_user
May 31st, 2010, 01:18 PM
I recently reinstalled 10.04, clean install with format. My windows 7 partition is fine but does not appear in Grub2, in fact i dont get a grub2 menu anymore but i know from running grub-mkconfig that it does not see windows7.

Generating grub.cfg ...
Found linux image: /boot/vmlinuz-2.6.32-22-generic
Found initrd image: /boot/initrd.img-2.6.32-22-generic
Found linux image: /boot/vmlinuz-2.6.32-21-generic
Found initrd image: /boot/initrd.img-2.6.32-21-generic
Found memtest86+ image: /boot/memtest86+.bin


I have never had this before so could somebody help me add windows7 back into grub?

thanks

darkod
May 31st, 2010, 01:50 PM
Run the boot info script as explained here and post the content of your results file:
http://ubuntuforums.org/showpost.php?p=8844901&postcount=4

confused_user
May 31st, 2010, 05:35 PM
here you go

thanks

here is the output


Boot Info Script 0.55 dated February 15th, 2010

============================= Boot Info Summary: ==============================

=> Grub 2 is installed in the MBR of /dev/sda and looks on the same drive in
partition #7 for /boot/grub.

sda1: __________________________________________________ _______________________

File system: swap
Boot sector type: -
Boot sector info:

sda4: __________________________________________________ _______________________

File system: Extended Partition
Boot sector type: Unknown
Boot sector info:

sda5: __________________________________________________ _______________________

File system: ntfs
Boot sector type: Windows Vista/7
Boot sector info: No errors found in the Boot Parameter Block.
Operating System: Windows 7
Boot files/dirs: /Windows/System32/winload.exe

sda6: __________________________________________________ _______________________

File system: ext3
Boot sector type: -
Boot sector info:
Operating System:
Boot files/dirs:

sda7: __________________________________________________ _______________________

File system: ext3
Boot sector type: -
Boot sector info:
Operating System: Ubuntu 10.04 LTS
Boot files/dirs: /boot/grub/grub.cfg /etc/fstab /boot/grub/core.img

=========================== Drive/Partition Info: =============================

Drive: sda ___________________ __________________________________________________ ___

Disk /dev/sda: 160.0 GB, 160041885696 bytes
255 heads, 63 sectors/track, 19457 cylinders, total 312581808 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes

Partition Boot Start End Size Id System

/dev/sda1 * 2,048 3,999,743 3,997,696 82 Linux swap / Solaris
/dev/sda4 4,001,790 312,576,704 308,574,915 5 Extended
/dev/sda5 25,495,155 103,956,614 78,461,460 7 HPFS/NTFS
/dev/sda6 124,439,553 312,576,704 188,137,152 83 Linux
/dev/sda7 4,001,792 25,483,263 21,481,472 83 Linux


blkid -c /dev/null: __________________________________________________ __________

Device UUID TYPE LABEL

/dev/sda1 dc82ad19-ee95-437c-9eec-07893d3c007a swap
/dev/sda4: PTTYPE="dos"
/dev/sda5 84E8FC48E8FC3A4E ntfs
/dev/sda6 b706b65e-5f29-46af-8bca-5bc118b1c612 ext3
/dev/sda7 d28f5b0d-8e22-4aaa-b152-bfee2f359195 ext3
/dev/sda: PTTYPE="dos"
error: /dev/sdb: No medium found

============================ "mount | grep ^/dev output: ===========================

Device Mount_Point Type Options

/dev/sda7 / ext3 (rw,errors=remount-ro)
/dev/sda6 /home ext3 (rw)


=========================== sda7/boot/grub/grub.cfg: ===========================

#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by /usr/sbin/grub-mkconfig using templates
# from /etc/grub.d and settings from /etc/default/grub
#

### BEGIN /etc/grub.d/00_header ###
if [ -s $prefix/grubenv ]; then
load_env
fi
set default="1"
if [ ${prev_saved_entry} ]; then
set saved_entry=${prev_saved_entry}
save_env saved_entry
set prev_saved_entry=
save_env prev_saved_entry
set boot_once=true
fi

function savedefault {
if [ -z ${boot_once} ]; then
saved_entry=${chosen}
save_env saved_entry
fi
}

function recordfail {
set recordfail=1
if [ -n ${have_grubenv} ]; then if [ -z ${boot_once} ]; then save_env recordfail; fi; fi
}
insmod ext2
set root='(hd0,7)'
search --no-floppy --fs-uuid --set d28f5b0d-8e22-4aaa-b152-bfee2f359195
if loadfont /usr/share/grub/unicode.pf2 ; then
set gfxmode=640x480
insmod gfxterm
insmod vbe
if terminal_output gfxterm ; then true ; else
# For backward compatibility with versions of terminal.mod that don't
# understand terminal_output
terminal gfxterm
fi
fi
insmod ext2
set root='(hd0,7)'
search --no-floppy --fs-uuid --set d28f5b0d-8e22-4aaa-b152-bfee2f359195
set locale_dir=($root)/boot/grub/locale
set lang=en
insmod gettext
if [ ${recordfail} = 1 ]; then
set timeout=-1
else
set timeout=10
fi
### END /etc/grub.d/00_header ###

### BEGIN /etc/grub.d/05_debian_theme ###
set menu_color_normal=white/black
set menu_color_highlight=black/light-gray
### END /etc/grub.d/05_debian_theme ###

### BEGIN /etc/grub.d/10_linux ###
menuentry 'Ubuntu, with Linux 2.6.32-22-generic' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod ext2
set root='(hd0,7)'
search --no-floppy --fs-uuid --set d28f5b0d-8e22-4aaa-b152-bfee2f359195
linux /boot/vmlinuz-2.6.32-22-generic root=UUID=d28f5b0d-8e22-4aaa-b152-bfee2f359195 ro quiet splash
initrd /boot/initrd.img-2.6.32-22-generic
}
menuentry 'Ubuntu, with Linux 2.6.32-22-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod ext2
set root='(hd0,7)'
search --no-floppy --fs-uuid --set d28f5b0d-8e22-4aaa-b152-bfee2f359195
echo 'Loading Linux 2.6.32-22-generic ...'
linux /boot/vmlinuz-2.6.32-22-generic root=UUID=d28f5b0d-8e22-4aaa-b152-bfee2f359195 ro single
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-2.6.32-22-generic
}
menuentry 'Ubuntu, with Linux 2.6.32-21-generic' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod ext2
set root='(hd0,7)'
search --no-floppy --fs-uuid --set d28f5b0d-8e22-4aaa-b152-bfee2f359195
linux /boot/vmlinuz-2.6.32-21-generic root=UUID=d28f5b0d-8e22-4aaa-b152-bfee2f359195 ro quiet splash
initrd /boot/initrd.img-2.6.32-21-generic
}
menuentry 'Ubuntu, with Linux 2.6.32-21-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod ext2
set root='(hd0,7)'
search --no-floppy --fs-uuid --set d28f5b0d-8e22-4aaa-b152-bfee2f359195
echo 'Loading Linux 2.6.32-21-generic ...'
linux /boot/vmlinuz-2.6.32-21-generic root=UUID=d28f5b0d-8e22-4aaa-b152-bfee2f359195 ro single
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-2.6.32-21-generic
}
### END /etc/grub.d/10_linux ###

### BEGIN /etc/grub.d/20_memtest86+ ###
menuentry "Memory test (memtest86+)" {
insmod ext2
set root='(hd0,7)'
search --no-floppy --fs-uuid --set d28f5b0d-8e22-4aaa-b152-bfee2f359195
linux16 /boot/memtest86+.bin
}
menuentry "Memory test (memtest86+, serial console 115200)" {
insmod ext2
set root='(hd0,7)'
search --no-floppy --fs-uuid --set d28f5b0d-8e22-4aaa-b152-bfee2f359195
linux16 /boot/memtest86+.bin console=ttyS0,115200n8
}
### END /etc/grub.d/20_memtest86+ ###

### BEGIN /etc/grub.d/30_os-prober ###
if [ ${timeout} != -1 ]; then
if keystatus; then
if keystatus --shift; then
set timeout=-1
else
set timeout=0
fi
else
if sleep --interruptible 3 ; then
set timeout=0
fi
fi
fi
### END /etc/grub.d/30_os-prober ###

### BEGIN /etc/grub.d/40_custom ###
# This file provides an easy way to add custom menu entries. Simply type the
# menu entries you want to add after this comment. Be careful not to change
# the 'exec tail' line above.
### END /etc/grub.d/40_custom ###

=============================== sda7/etc/fstab: ===============================

# /etc/fstab: static file system information.
#
# Use 'blkid -o value -s UUID' to print the universally unique identifier
# for a device; this may be used with UUID= as a more robust way to name
# devices that works even if disks are added and removed. See fstab(5).
#
# <file system> <mount point> <type> <options> <dump> <pass>
proc /proc proc nodev,noexec,nosuid 0 0
# / was on /dev/sda7 during installation
UUID=d28f5b0d-8e22-4aaa-b152-bfee2f359195 / ext3 errors=remount-ro 0 1
# /home was on /dev/sda6 during installation
UUID=b706b65e-5f29-46af-8bca-5bc118b1c612 /home ext3 defaults 0 2
/dev/sda1 none swap sw 0 0

=================== sda7: Location of files loaded by Grub: ===================


8.7GB: boot/grub/core.img
8.8GB: boot/grub/grub.cfg
8.8GB: boot/initrd.img-2.6.32-21-generic
8.8GB: boot/initrd.img-2.6.32-22-generic
8.9GB: boot/vmlinuz-2.6.32-21-generic
8.7GB: boot/vmlinuz-2.6.32-22-generic
8.8GB: initrd.img
8.8GB: initrd.img.old
8.7GB: vmlinuz
8.9GB: vmlinuz.old
=========================== Unknown MBRs/Boot Sectors/etc =======================

Unknown BootLoader on sda4

00000000 a2 b0 87 14 02 a7 77 e9 2e b8 74 f7 9f a5 d7 dd |......w...t.....|
00000010 f7 e8 10 ae f4 d3 95 2c dd 7e 93 8e 07 25 fa e2 |.......,.~...%..|
00000020 63 ba e9 2b 8f f1 c3 99 89 fc 04 cb a7 59 fe 0e |c..+.........Y..|
00000030 9b ee 65 f9 3c cb af b0 fc 24 cb 67 d9 74 9f c4 |..e.<....$.g.t..|
00000040 f2 3d 18 34 dd c7 f2 03 f0 f9 97 4e 0c ea 67 d3 |.=.4.......N..g.|
00000050 9d f6 8d 59 3a 85 cb f3 6c ba c7 a3 ef c4 a1 a3 |...Y:...l.......|
00000060 3f 8f 2e fd 63 3a fb cb ed 19 4a ea ff 49 67 7e |?...c:....J..Ig~|
00000070 1e 9e f5 68 05 ca d7 27 70 28 4b 4d ea 8b 81 68 |...h...'p(KM...h|
00000080 22 8a d9 53 fa 58 86 0c 50 9c f0 68 aa dd 3d 41 |"..S.X..P..h..=A|
00000090 6e 4d 09 d1 9f f5 c2 fa 0a cd 84 75 6e a4 71 ae |nM.........un.q.|
000000a0 6b a3 d7 9b ed 98 dd 0a c7 5e 4c d3 b3 aa 2f 06 |k........^L.../.|
000000b0 43 ab 77 92 06 8c ad 3c 16 ff 98 bd c4 b3 fa 3c |C.w....<.......<|
000000c0 65 4e 3f d0 e0 f9 c5 98 ee 31 c7 c7 e5 5d ab d5 |eN?......1...]..|
000000d0 2b 1c ab d5 78 f8 d0 d1 d3 34 8e 94 92 72 8b 1a |+...x....4...r..|
000000e0 6a a7 ea a3 38 e3 b5 90 c6 a3 35 d6 ed 72 94 0a |j...8.....5..r..|
000000f0 eb cf e1 3d ad e0 7c 9d 35 69 97 c3 89 ba f5 45 |...=..|.5i.....E|
00000100 6b 4e af e0 d1 11 b4 c3 6c 66 82 cd a4 d9 cc 1d |kN......lf......|
00000110 36 db cb 66 a6 d9 cc 0a 9b 99 64 33 59 36 4b 05 |6..f......d3Y6K.|
00000120 81 9a cf 99 7e 36 db 49 37 2e b3 99 51 b8 62 7e |....~6.I7...Q.b~|
00000130 7a 74 a6 55 64 3c 7a 9e 69 ca 6d bd eb 4b d2 fa |zt.Ud<z.i.m..K..|
00000140 bc 39 eb b8 3e ed d1 ae be e3 fb b5 5a 7f 78 a7 |.9..>.......Z.x.|
00000150 18 00 ef f4 b2 f7 77 9a 74 de e9 f1 54 58 d6 cd |......w.t...TX..|
00000160 de a5 37 1b 5a d3 1e 13 4c 51 cf 6b 06 9a b2 5b |..7.Z...LQ.k...[|
00000170 a6 86 dc dc 09 8f 7d b9 22 5f 77 b1 cc 77 74 fe |......}."_w..wt.|
00000180 d0 ca e3 78 6f 96 65 ee d3 57 33 74 c9 63 f3 a4 |...xo.e..W3t.c..|
00000190 c5 4a eb 20 66 31 4d 28 46 52 d1 70 21 d6 a3 25 |.J. f1M(FR.p!..%|
000001a0 6d 8f 44 4a b4 b6 26 15 c3 63 3a 25 9a 0f 1d 3d |m.DJ..&..c:%...=|
000001b0 81 fd d6 62 d6 ec b8 16 f3 fe e7 44 13 98 00 fe |...b.......D....|
000001c0 ff ff 07 fe ff ff 75 f6 47 01 14 3a ad 04 00 fe |......u.G..:....|
000001d0 ff ff 05 fe ff ff c4 bb 2d 07 ff be 36 0b 00 00 |........-...6...|
000001e0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................|
000001f0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 55 aa |..............U.|
00000200


=======Devices which don't seem to have a corresponding hard drive==============

sdb

darkod
May 31st, 2010, 05:49 PM
Were you trying to move partitions around or something similar?


Drive: sda ___________________ __________________________________________________ ___

Disk /dev/sda: 160.0 GB, 160041885696 bytes
255 heads, 63 sectors/track, 19457 cylinders, total 312581808 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes

Partition Boot Start End Size Id System

/dev/sda1 * 2,048 3,999,743 3,997,696 82 Linux swap / Solaris
/dev/sda4 4,001,790 312,576,704 308,574,915 5 Extended
/dev/sda5 25,495,155 103,956,614 78,461,460 7 HPFS/NTFS
/dev/sda6 124,439,553 312,576,704 188,137,152 83 Linux
/dev/sda7 4,001,792 25,483,263 21,481,472 83 Linux

Anyway, it seems you had the small win7 boot partition which is holding the boot files. Now it's not there. Also, your win7 system partition is a logical partition which further complicates things.

The windows boot files need to be on a primary partition but you don't seem to have unallocated space to create one right now.

Any why the swap partition as primary?

In theory, you could:
- in live mode, delete the swap partition, or better yet just shrink it for 100MB
- create a new primary ntfs partition of 100MB from that unallocated space.
- use Gparted to set a boot flag on the 100MB ntfs partition
- boot with the win7 install dvd and use the boot files restore command (/fixboot) as explained here (note: if you also rub /fixmbr you will need to reinstall grub2 to the MBR, /fixboot should be enough):
http://ubuntuforums.org/showthread.php?t=1014708

oldfred
May 31st, 2010, 05:53 PM
You deleted another copy of windows installed or the windows boot/recoverypartition. Your windows install is in sda5 which is a logical partition inside the extended partition. Windows can only boot from a primary partition. (there may have been exceptions but it is not easy to do and I do not know how.)

To understand how windows boots:
To get each MS to have its own boot loader make a partition and set its boot flag on, then install the 2nd product in it. Multibooters, Pictures here worth 1000+ words
http://www.multibooters.co.uk/multiboot.html

confused_user
May 31st, 2010, 06:06 PM
right, after this happened(one of the reasons i reinstalled) was to create a smaller root partition and give more space to the windows partition. So yes.

I also had an OEM partition of about 4GB which i deleted - i guess my MBR was in there?

no idea why swap is a primary, i just used the ubuntu installer to create it and thats how it turned out.

Thanks for the tips, i will try them out and post back

confused_user
May 31st, 2010, 10:51 PM
ok i can now boot windows from MBR (installed on /dev/sda2) and i can boot linux from grub

what i cant do is boot windows 7 from grub.

i used a usb stick to fix the mbr (/dev/sdd1)

now for some reason, when install grub i get my linux kernels fine and they work but the windows entry refers to /dev/sdd1 and not /dev/sda2 where i installed the mbr as suggested above

???


Boot Info Script 0.55 dated February 15th, 2010

============================= Boot Info Summary: ==============================

=> Grub 2 is installed in the MBR of /dev/sda and looks on the same drive in
partition #7 for /boot/grub.

sda1: __________________________________________________ _______________________

File system: swap
Boot sector type: -
Boot sector info:

sda2: __________________________________________________ _______________________

File system: ntfs
Boot sector type: Windows Vista/7
Boot sector info: No errors found in the Boot Parameter Block.
Operating System:
Boot files/dirs: /bootmgr /Boot/BCD

sda4: __________________________________________________ _______________________

File system: Extended Partition
Boot sector type: -
Boot sector info:

sda5: __________________________________________________ _______________________

File system: ntfs
Boot sector type: Windows Vista/7
Boot sector info: No errors found in the Boot Parameter Block.
Operating System: Windows 7
Boot files/dirs: /Windows/System32/winload.exe

sda6: __________________________________________________ _______________________

File system: ext3
Boot sector type: -
Boot sector info:
Operating System:
Boot files/dirs:

sda7: __________________________________________________ _______________________

File system: ext3
Boot sector type: -
Boot sector info:
Operating System: Ubuntu 10.04 LTS
Boot files/dirs: /boot/grub/grub.cfg /etc/fstab /boot/grub/core.img

=========================== Drive/Partition Info: =============================

Drive: sda ___________________ __________________________________________________ ___

Disk /dev/sda: 160.0 GB, 160041885696 bytes
255 heads, 63 sectors/track, 19457 cylinders, total 312581808 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes

Partition Boot Start End Size Id System

/dev/sda1 2,048 2,072,384 2,070,337 82 Linux swap / Solaris
/dev/sda2 * 2,072,385 4,000,184 1,927,800 7 HPFS/NTFS
/dev/sda4 4,001,790 312,576,704 308,574,915 5 Extended
/dev/sda5 25,495,155 103,956,614 78,461,460 7 HPFS/NTFS
/dev/sda6 124,439,553 312,576,704 188,137,152 83 Linux
/dev/sda7 4,001,792 25,483,263 21,481,472 83 Linux


blkid -c /dev/null: __________________________________________________ __________

Device UUID TYPE LABEL

/dev/sda1 dc82ad19-ee95-437c-9eec-07893d3c007a swap
/dev/sda2 2B705445189857D1 ntfs mbr
/dev/sda4: PTTYPE="dos"
/dev/sda5 84E8FC48E8FC3A4E ntfs
/dev/sda6 b706b65e-5f29-46af-8bca-5bc118b1c612 ext3
/dev/sda7 d28f5b0d-8e22-4aaa-b152-bfee2f359195 ext3
/dev/sda: PTTYPE="dos"
error: /dev/sdb: No medium found

============================ "mount | grep ^/dev output: ===========================

Device Mount_Point Type Options

/dev/sda7 / ext3 (rw,errors=remount-ro)
/dev/sda6 /home ext3 (rw)


=========================== sda7/boot/grub/grub.cfg: ===========================

#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by /usr/sbin/grub-mkconfig using templates
# from /etc/grub.d and settings from /etc/default/grub
#

### BEGIN /etc/grub.d/00_header ###
if [ -s $prefix/grubenv ]; then
load_env
fi
set default="1"
if [ ${prev_saved_entry} ]; then
set saved_entry=${prev_saved_entry}
save_env saved_entry
set prev_saved_entry=
save_env prev_saved_entry
set boot_once=true
fi

function savedefault {
if [ -z ${boot_once} ]; then
saved_entry=${chosen}
save_env saved_entry
fi
}

function recordfail {
set recordfail=1
if [ -n ${have_grubenv} ]; then if [ -z ${boot_once} ]; then save_env recordfail; fi; fi
}
insmod ext2
set root='(hd0,7)'
search --no-floppy --fs-uuid --set d28f5b0d-8e22-4aaa-b152-bfee2f359195
if loadfont /usr/share/grub/unicode.pf2 ; then
set gfxmode=640x480
insmod gfxterm
insmod vbe
if terminal_output gfxterm ; then true ; else
# For backward compatibility with versions of terminal.mod that don't
# understand terminal_output
terminal gfxterm
fi
fi
insmod ext2
set root='(hd0,7)'
search --no-floppy --fs-uuid --set d28f5b0d-8e22-4aaa-b152-bfee2f359195
set locale_dir=($root)/boot/grub/locale
set lang=en
insmod gettext
if [ ${recordfail} = 1 ]; then
set timeout=-1
else
set timeout=10
fi
### END /etc/grub.d/00_header ###

### BEGIN /etc/grub.d/05_debian_theme ###
set menu_color_normal=white/black
set menu_color_highlight=black/light-gray
### END /etc/grub.d/05_debian_theme ###

### BEGIN /etc/grub.d/10_linux ###
menuentry 'Ubuntu, with Linux 2.6.32-22-generic' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod ext2
set root='(hd0,7)'
search --no-floppy --fs-uuid --set d28f5b0d-8e22-4aaa-b152-bfee2f359195
linux /boot/vmlinuz-2.6.32-22-generic root=UUID=d28f5b0d-8e22-4aaa-b152-bfee2f359195 ro quiet splash
initrd /boot/initrd.img-2.6.32-22-generic
}
menuentry 'Ubuntu, with Linux 2.6.32-22-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod ext2
set root='(hd0,7)'
search --no-floppy --fs-uuid --set d28f5b0d-8e22-4aaa-b152-bfee2f359195
echo 'Loading Linux 2.6.32-22-generic ...'
linux /boot/vmlinuz-2.6.32-22-generic root=UUID=d28f5b0d-8e22-4aaa-b152-bfee2f359195 ro single
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-2.6.32-22-generic
}
menuentry 'Ubuntu, with Linux 2.6.32-21-generic' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod ext2
set root='(hd0,7)'
search --no-floppy --fs-uuid --set d28f5b0d-8e22-4aaa-b152-bfee2f359195
linux /boot/vmlinuz-2.6.32-21-generic root=UUID=d28f5b0d-8e22-4aaa-b152-bfee2f359195 ro quiet splash
initrd /boot/initrd.img-2.6.32-21-generic
}
menuentry 'Ubuntu, with Linux 2.6.32-21-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod ext2
set root='(hd0,7)'
search --no-floppy --fs-uuid --set d28f5b0d-8e22-4aaa-b152-bfee2f359195
echo 'Loading Linux 2.6.32-21-generic ...'
linux /boot/vmlinuz-2.6.32-21-generic root=UUID=d28f5b0d-8e22-4aaa-b152-bfee2f359195 ro single
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-2.6.32-21-generic
}
### END /etc/grub.d/10_linux ###

### BEGIN /etc/grub.d/20_memtest86+ ###
menuentry "Memory test (memtest86+)" {
insmod ext2
set root='(hd0,7)'
search --no-floppy --fs-uuid --set d28f5b0d-8e22-4aaa-b152-bfee2f359195
linux16 /boot/memtest86+.bin
}
menuentry "Memory test (memtest86+, serial console 115200)" {
insmod ext2
set root='(hd0,7)'
search --no-floppy --fs-uuid --set d28f5b0d-8e22-4aaa-b152-bfee2f359195
linux16 /boot/memtest86+.bin console=ttyS0,115200n8
}
### END /etc/grub.d/20_memtest86+ ###

### BEGIN /etc/grub.d/30_os-prober ###
menuentry "Windows Vista (loader) (on /dev/sdd1)" {
insmod ntfs
set root='(hd1,1)'
search --no-floppy --fs-uuid --set 7a3e34653e341c97
chainloader +1
}
### END /etc/grub.d/30_os-prober ###

### BEGIN /etc/grub.d/40_custom ###
# This file provides an easy way to add custom menu entries. Simply type the
# menu entries you want to add after this comment. Be careful not to change
# the 'exec tail' line above.
### END /etc/grub.d/40_custom ###

=============================== sda7/etc/fstab: ===============================

# /etc/fstab: static file system information.
#
# Use 'blkid -o value -s UUID' to print the universally unique identifier
# for a device; this may be used with UUID= as a more robust way to name
# devices that works even if disks are added and removed. See fstab(5).
#
# <file system> <mount point> <type> <options> <dump> <pass>
proc /proc proc nodev,noexec,nosuid 0 0
# / was on /dev/sda7 during installation
UUID=d28f5b0d-8e22-4aaa-b152-bfee2f359195 / ext3 errors=remount-ro 0 1
# /home was on /dev/sda6 during installation
UUID=b706b65e-5f29-46af-8bca-5bc118b1c612 /home ext3 defaults 0 2
/dev/sda1 none swap sw 0 0

=================== sda7: Location of files loaded by Grub: ===================


8.7GB: boot/grub/core.img
8.8GB: boot/grub/grub.cfg
8.8GB: boot/initrd.img-2.6.32-21-generic
8.8GB: boot/initrd.img-2.6.32-22-generic
8.9GB: boot/vmlinuz-2.6.32-21-generic
8.7GB: boot/vmlinuz-2.6.32-22-generic
8.8GB: initrd.img
8.8GB: initrd.img.old
8.7GB: vmlinuz
8.9GB: vmlinuz.old
=======Devices which don't seem to have a corresponding hard drive==============

sdb

darkod
May 31st, 2010, 10:58 PM
Now that the usb stick is unplugged, boot ubuntu and try:

sudo update-grub

That should report win7 as found.

confused_user
June 1st, 2010, 12:21 PM
nope,



matt@matt-netbook:~$ sudo update-grub
[sudo] password for matt:
head: cannot open `/boot/grub/video.lst' for reading: No such file or directory
Generating grub.cfg ...
Found linux image: /boot/vmlinuz-2.6.32-22-generic
Found initrd image: /boot/initrd.img-2.6.32-22-generic
Found linux image: /boot/vmlinuz-2.6.32-21-generic
Found initrd image: /boot/initrd.img-2.6.32-21-generic
Found memtest86+ image: /boot/memtest86+.bin
ls: cannot access /var/lib/os-prober/mount/Boot
boot: No such file or directory
done


really appreciate your help with this by the way :D

confused_user
June 1st, 2010, 01:14 PM
righto then, i did some exploring and it turns out i had a /boot folder on /dev/sda2 alongside /BOOT (which has mbr in it).

So i deleted the /boot and viola

it all works from grub now.

thanks for you help dude and i have no idea how all this happened. never had so much grief with a boot loader before :D