LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (http://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Bootmgr is missing on ubuntu and windows 7 dual boot (http://www.linuxquestions.org/questions/linux-newbie-8/bootmgr-is-missing-on-ubuntu-and-windows-7-dual-boot-874164/)

bomberb17 04-10-2011 05:03 PM

Bootmgr is missing on ubuntu and windows 7 dual boot
 
Hello, I was having a dual-boot configuration, Ubuntu 10.10 and Windows 7 on the same disk. After resizing the windows 7 partition, after this screen
http://www.linuxbsdos.com/wp-content...13-575x431.png
and after selecting windows 7 , I get "bootmgr is missing" message. Ubuntu loads normally.
Here's my results.txt from boot info script:
Quote:

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 #5 for (,msdos5)/boot/grub.

sda1: _________________________________________________________________________

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:

sda2: _________________________________________________________________________

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

sda5: _________________________________________________________________________

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

sda6: _________________________________________________________________________

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

sda3: _________________________________________________________________________

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

=========================== 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 101,359,615 101,357,568 7 HPFS/NTFS
/dev/sda2 101,361,662 154,466,303 53,104,642 5 Extended
/dev/sda5 101,361,664 152,178,687 50,817,024 83 Linux
/dev/sda6 152,180,736 154,466,303 2,285,568 82 Linux swap / Solaris
/dev/sda3 154,466,304 312,580,095 158,113,792 7 HPFS/NTFS


blkid -c /dev/null: ____________________________________________________________

Device UUID TYPE LABEL

/dev/sda1 FA145A7F145A3EB7 ntfs
/dev/sda2: PTTYPE="dos"
/dev/sda3 EE8ACC568ACC1CC9 ntfs
/dev/sda5 821f6e69-0e93-4294-81d1-c9ba64bce4a2 ext4
/dev/sda6 c921f70c-5a59-4eee-bc09-ac4f0f300af7 swap
/dev/sda: PTTYPE="dos"

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

Device Mount_Point Type Options

/dev/sda5 / ext4 (rw,errors=remount-ro,commit=0)


=========================== sda5/boot/grub/grub.cfg: ===========================

#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by 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
set have_grubenv=true
load_env
fi
set default="0"
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
}

function load_video {
insmod vbe
insmod vga
}

insmod part_msdos
insmod ext2
set root='(hd0,msdos5)'
search --no-floppy --fs-uuid --set 821f6e69-0e93-4294-81d1-c9ba64bce4a2
if loadfont /usr/share/grub/unicode.pf2 ; then
set gfxmode=640x480
load_video
insmod gfxterm
fi
terminal_output gfxterm
insmod part_msdos
insmod ext2
set root='(hd0,msdos5)'
search --no-floppy --fs-uuid --set 821f6e69-0e93-4294-81d1-c9ba64bce4a2
set locale_dir=($root)/boot/grub/locale
set lang=el
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.35-24-generic' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod part_msdos
insmod ext2
set root='(hd0,msdos5)'
search --no-floppy --fs-uuid --set 821f6e69-0e93-4294-81d1-c9ba64bce4a2
linux /boot/vmlinuz-2.6.35-24-generic root=UUID=821f6e69-0e93-4294-81d1-c9ba64bce4a2 ro quiet splash
initrd /boot/initrd.img-2.6.35-24-generic
}
menuentry 'Ubuntu, with Linux 2.6.35-24-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod part_msdos
insmod ext2
set root='(hd0,msdos5)'
search --no-floppy --fs-uuid --set 821f6e69-0e93-4294-81d1-c9ba64bce4a2
echo 'Loading Linux 2.6.35-24-generic ...'
linux /boot/vmlinuz-2.6.35-24-generic root=UUID=821f6e69-0e93-4294-81d1-c9ba64bce4a2 ro single
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-2.6.35-24-generic
}
menuentry 'Ubuntu, with Linux 2.6.35-23-generic' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod part_msdos
insmod ext2
set root='(hd0,msdos5)'
search --no-floppy --fs-uuid --set 821f6e69-0e93-4294-81d1-c9ba64bce4a2
linux /boot/vmlinuz-2.6.35-23-generic root=UUID=821f6e69-0e93-4294-81d1-c9ba64bce4a2 ro quiet splash
initrd /boot/initrd.img-2.6.35-23-generic
}
menuentry 'Ubuntu, with Linux 2.6.35-23-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod part_msdos
insmod ext2
set root='(hd0,msdos5)'
search --no-floppy --fs-uuid --set 821f6e69-0e93-4294-81d1-c9ba64bce4a2
echo 'Loading Linux 2.6.35-23-generic ...'
linux /boot/vmlinuz-2.6.35-23-generic root=UUID=821f6e69-0e93-4294-81d1-c9ba64bce4a2 ro single
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-2.6.35-23-generic
}
menuentry 'Ubuntu, with Linux 2.6.35-22-generic' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod part_msdos
insmod ext2
set root='(hd0,msdos5)'
search --no-floppy --fs-uuid --set 821f6e69-0e93-4294-81d1-c9ba64bce4a2
linux /boot/vmlinuz-2.6.35-22-generic root=UUID=821f6e69-0e93-4294-81d1-c9ba64bce4a2 ro quiet splash
initrd /boot/initrd.img-2.6.35-22-generic
}
menuentry 'Ubuntu, with Linux 2.6.35-22-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod part_msdos
insmod ext2
set root='(hd0,msdos5)'
search --no-floppy --fs-uuid --set 821f6e69-0e93-4294-81d1-c9ba64bce4a2
echo 'Loading Linux 2.6.35-22-generic ...'
linux /boot/vmlinuz-2.6.35-22-generic root=UUID=821f6e69-0e93-4294-81d1-c9ba64bce4a2 ro single
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-2.6.35-22-generic
}
### END /etc/grub.d/10_linux ###

### BEGIN /etc/grub.d/20_linux_xen ###
### END /etc/grub.d/20_linux_xen ###

### BEGIN /etc/grub.d/20_memtest86+ ###
menuentry "Memory test (memtest86+)" {
insmod part_msdos
insmod ext2
set root='(hd0,msdos5)'
search --no-floppy --fs-uuid --set 821f6e69-0e93-4294-81d1-c9ba64bce4a2
linux16 /boot/memtest86+.bin
}
menuentry "Memory test (memtest86+, serial console 115200)" {
insmod part_msdos
insmod ext2
set root='(hd0,msdos5)'
search --no-floppy --fs-uuid --set 821f6e69-0e93-4294-81d1-c9ba64bce4a2
linux16 /boot/memtest86+.bin console=ttyS0,115200n8
}
### END /etc/grub.d/20_memtest86+ ###

### BEGIN /etc/grub.d/30_os-prober ###
### 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 ###

### BEGIN /etc/grub.d/41_custom ###
if [ -f $prefix/custom.cfg ]; then
source $prefix/custom.cfg;
fi
### END /etc/grub.d/41_custom ###

=============================== sda5/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/sda5 during installation
UUID=821f6e69-0e93-4294-81d1-c9ba64bce4a2 / ext4 errors=remount-ro 0 1
# swap was on /dev/sda6 during installation
UUID=c921f70c-5a59-4eee-bc09-ac4f0f300af7 none swap sw 0 0

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


58.4GB: boot/grub/core.img
71.5GB: boot/grub/grub.cfg
53.3GB: boot/initrd.img-2.6.35-22-generic
52.4GB: boot/initrd.img-2.6.35-23-generic
54.6GB: boot/initrd.img-2.6.35-24-generic
58.4GB: boot/vmlinuz-2.6.35-22-generic
58.4GB: boot/vmlinuz-2.6.35-23-generic
58.6GB: boot/vmlinuz-2.6.35-24-generic
54.6GB: initrd.img
52.4GB: initrd.img.old
58.6GB: vmlinuz
58.4GB: vmlinuz.old
=========================== Unknown MBRs/Boot Sectors/etc =======================

Unknown BootLoader on sda2

00000000 75 05 b8 07 05 00 00 c3 cc cc cc cc cc 6a 34 68 |u............j4h|
00000010 48 27 40 00 e8 17 e7 00 00 8d 45 d4 50 8d 45 d0 |H'@.......E.P.E.|
00000020 50 8d 45 e0 50 ff 75 08 e8 3e e0 00 00 89 45 e4 |P.E.P.u..>....E.|
00000030 33 db 3b c3 74 0e ff 75 08 ff 15 bc 10 40 00 e9 |3.;.t..u.....@..|
00000040 67 01 00 00 89 5d fc 8b 45 d4 89 45 dc 8b 4d e0 |g....]..E..E..M.|
00000050 83 f9 02 72 1b 66 81 38 ff fe 75 14 c7 45 d8 01 |...r.f.8..u..E..|
00000060 00 00 00 83 c0 02 89 45 dc 49 49 89 4d e0 eb 0f |.......E.II.M...|
00000070 53 51 50 ff 15 24 10 40 00 89 45 d8 8b 4d e0 83 |SQP..$.@..E..M..|
00000080 4d fc ff eb 2b 8b 45 ec 8b 00 8b 00 89 45 cc 50 |M...+.E......E.P|
00000090 e8 c7 a0 ff ff c3 8b 65 e8 8d 45 e4 50 6a 1e ff |.......e..E.Pj..|
000000a0 75 cc e8 dc a0 ff ff 83 4d fc ff 33 db 8b 4d e0 |u.......M..3..M.|
000000b0 39 5d e4 0f 85 e4 00 00 00 39 5d d8 74 24 8b 45 |9].......9].t$.E|
000000c0 0c 8b 55 dc 89 10 d1 e9 89 48 04 8b 4d 08 89 48 |..U......H..M..H|
000000d0 08 8b 4d d0 89 48 0c 8b 4d d4 89 48 10 e9 b1 00 |..M..H..M..H....|
000000e0 00 00 8d 04 09 50 e8 2b d8 00 00 8b f0 89 75 c4 |.....P.+......u.|
000000f0 3b f3 74 68 33 ff 47 89 7d fc 89 5d bc 53 ff 15 |;.th3.G.}..].S..|
00000100 a8 10 40 00 ff 75 e0 56 ff 75 e0 ff 75 dc 57 53 |..@..u.V.u..u.WS|
00000110 ff 15 98 11 40 00 89 45 c0 3b c3 74 04 33 c0 eb |....@..E.;.t.3..|
00000120 05 e8 d2 fe ff ff 89 45 e4 83 4d fc ff eb 34 8b |.......E..M...4.|
00000130 45 ec 8b 00 8b 00 89 45 c8 50 e8 1d a0 ff ff c3 |E......E.P......|
00000140 8b 65 e8 8d 45 e4 50 6a 1e ff 75 c8 e8 32 a0 ff |.e..E.Pj..u..2..|
00000150 ff 83 4d fc ff 33 db 8b 75 c4 eb 07 c7 45 e4 08 |..M..3..u....E..|
00000160 00 00 00 39 5d e4 75 21 8b 7d c0 8d 04 3f 50 56 |...9].u!.}...?PV|
00000170 e8 e2 d7 00 00 8b 4d 0c 89 01 3b c3 75 02 89 31 |......M...;.u..1|
00000180 89 79 04 83 49 08 ff eb 0a 3b f3 74 06 56 e8 05 |.y..I....;.t.V..|
00000190 d8 00 00 39 5d e4 75 05 39 5d d8 75 0e ff 75 d4 |...9].u.9].u..u.|
000001a0 ff 75 d0 ff 75 08 e8 38 df 00 00 8b 45 e4 e8 b8 |.u..u..8....E...|
000001b0 e5 00 00 c2 0c 00 cc cc cc cc cc 6a 14 68 00 fe |...........j.h..|
000001c0 ff ff 83 fe ff ff 02 00 00 00 00 68 07 03 00 fe |...........h....|
000001d0 ff ff 05 fe ff ff 02 68 07 03 00 e8 22 00 00 00 |.......h...."...|
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

Can someone help?

aus9 04-10-2011 06:24 PM

hi

can you name the program=tool you used to resize pls

1) suggest you load your windows disc and try either fixmbr or recovery and ntfs journal seems to have got corrupted probably thru resize tool

2) this will install w7 bootloader back into mbr and link to its booting file but normally fix the journal entry as well

3) reboot into windows to confirm its ok then

4) boot a linux live cd and run a special chroot to redo grub-install

http://techpatterns.com/forums/about1716.html

but change sda1 to sda5

good luck

bomberb17 04-10-2011 07:39 PM

Situation got worse. Tried to use bootrec /fixmbr from windows 7 DVD, now even ubuntu won't boot (grub boot loader seems to have been deleted). I am now booting from the ubuntu live cd. What can I do now?? Please help!!

spiderbatdad 04-10-2011 07:56 PM

maybe take a look a your partitions:
Code:

sudo fdisk -l
Should get you something like this:
Code:

  Device Boot      Start        End      Blocks  Id  System
/dev/sda1              1        784    6297448+  12  Compaq diagnostics
/dev/sda2  *        785        6766    48046875    7  HPFS/NTFS
/dev/sda3            6767      12845    48829567+  83  Linux
/dev/sda4          12846      19457    53110828    5  Extended
/dev/sda5          19235      19457    1791216  82  Linux swap / Solaris
/dev/sda6          12846      19234    51319548  83  Linux

In this case if I had lost my boot record and I know grub was installed on sda3 I would try this:
Code:

grub
grub> root (hd0,2)
grub> setup (hd0)

Notice sda3 is the equivalent of hd0,2. And so on. So sda5 would be hd0,4, and sdb2 would be hd1,1. Good luck.

bomberb17 04-10-2011 08:00 PM

sudo fdisk -l outputs this:

Code:

Disk /dev/sda: 160.0 GB, 160041885696 bytes
255 heads, 63 sectors/track, 19457 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x4a9f539b

  Device Boot      Start        End      Blocks  Id  System
/dev/sda2            6310        9616    26552321    5  Extended
/dev/sda3            9616      19458    79056896    7  HPFS/NTFS
/dev/sda5            6310        9473    25408512  83  Linux
/dev/sda6            9473        9616    1142784  82  Linux swap / Solaris

And I get this:
Code:

grub> root (hd0,4)
root (hd0,4)

Error 21: Selected disk does not exist


syg00 04-10-2011 08:40 PM

There's a lot of inconsistencies here. Implies we're not being told everything.

At a rough guess I'd say you actually reformatted (rather than just resize) sda1 - which had all your windows boot files. Then deleted sda1. Then apparently (re-)run update-grub.

Let's see another bootinfoscript output as it is now.


All times are GMT -5. The time now is 01:03 AM.