PDA

View Full Version : [ubuntu] error: no such device...dual boot problem



Zeppfan
June 9th, 2010, 10:07 PM
SO, I installed XP on a 60GB HDD. Then installed Karmic on a separate 120GB HDD. GRUB2 recognizes the XP drive, but when I try to boot into XP, I get the above message...error: no such device. I can boot into Karmic with no problems. I ran sudo bash ~/Downloads/boot_info_script*.sh and got these results:


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 #1 for /boot/grub.
=> Grub 2 is installed in the MBR of /dev/sdb and looks on the same drive in
partition #1 for /boot/grub.

sda1: __________________________________________________ _______________________

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

sda2: __________________________________________________ _______________________

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

sda5: __________________________________________________ _______________________

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

sdb1: __________________________________________________ _______________________

File system: ntfs
Boot sector type: Grub 2
Boot sector info: Grub 2 is installed in the boot sector of sdb1 and
looks at sector 271999 of the same hard drive for
core.img, but core.img can not be found at this
location. No errors found in the Boot Parameter Block.
Operating System: Windows XP
Boot files/dirs: /ntldr /ntdetect.com

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

Drive: sda ___________________ __________________________________________________ ___

Disk /dev/sda: 120.0 GB, 120034123776 bytes
255 heads, 63 sectors/track, 14593 cylinders, total 234441648 sectors
Units = sectors of 1 * 512 = 512 bytes
Disk identifier: 0x5c7fb438

Partition Boot Start End Size Id System

/dev/sda1 * 63 224,829,674 224,829,612 83 Linux
/dev/sda2 224,829,675 234,436,544 9,606,870 5 Extended
/dev/sda5 224,829,738 234,436,544 9,606,807 82 Linux swap / Solaris


Drive: sdb ___________________ __________________________________________________ ___

Disk /dev/sdb: 60.1 GB, 60060155904 bytes
255 heads, 63 sectors/track, 7301 cylinders, total 117304992 sectors
Units = sectors of 1 * 512 = 512 bytes
Disk identifier: 0xf08af08a

Partition Boot Start End Size Id System

/dev/sdb1 * 63 117,274,499 117,274,437 7 HPFS/NTFS


blkid -c /dev/null: __________________________________________________ __________

Device UUID TYPE LABEL

/dev/sda1 f23b953c-f0bf-418a-8177-935671217d67 ext4
/dev/sda5 d5e193ae-83e8-4f24-aa08-866ba4ba2a2f swap
/dev/sdb1 94DC82ADDC8288E6 ntfs

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

Device Mount_Point Type Options

/dev/sda1 / ext4 (rw,errors=remount-ro)


=========================== sda1/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 /boot/grub/grubenv ]; then
have_grubenv=true
load_env
fi
set default="0"
if [ ${prev_saved_entry} ]; then
saved_entry=${prev_saved_entry}
save_env saved_entry
prev_saved_entry=
save_env prev_saved_entry
fi
insmod ext2
set root=(hd0,1)
search --no-floppy --fs-uuid --set f23b953c-f0bf-418a-8177-935671217d67
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
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/white
### END /etc/grub.d/05_debian_theme ###

### BEGIN /etc/grub.d/10_linux ###
menuentry "Ubuntu, Linux 2.6.31-22-generic" {
recordfail=1
if [ -n ${have_grubenv} ]; then save_env recordfail; fi
set quiet=1
insmod ext2
set root=(hd0,1)
search --no-floppy --fs-uuid --set f23b953c-f0bf-418a-8177-935671217d67
linux /boot/vmlinuz-2.6.31-22-generic root=UUID=f23b953c-f0bf-418a-8177-935671217d67 ro quiet splash
initrd /boot/initrd.img-2.6.31-22-generic
}
menuentry "Ubuntu, Linux 2.6.31-22-generic (recovery mode)" {
recordfail=1
if [ -n ${have_grubenv} ]; then save_env recordfail; fi
insmod ext2
set root=(hd0,1)
search --no-floppy --fs-uuid --set f23b953c-f0bf-418a-8177-935671217d67
linux /boot/vmlinuz-2.6.31-22-generic root=UUID=f23b953c-f0bf-418a-8177-935671217d67 ro single
initrd /boot/initrd.img-2.6.31-22-generic
}
menuentry "Ubuntu, Linux 2.6.31-14-generic" {
recordfail=1
if [ -n ${have_grubenv} ]; then save_env recordfail; fi
set quiet=1
insmod ext2
set root=(hd0,1)
search --no-floppy --fs-uuid --set f23b953c-f0bf-418a-8177-935671217d67
linux /boot/vmlinuz-2.6.31-14-generic root=UUID=f23b953c-f0bf-418a-8177-935671217d67 ro quiet splash
initrd /boot/initrd.img-2.6.31-14-generic
}
menuentry "Ubuntu, Linux 2.6.31-14-generic (recovery mode)" {
recordfail=1
if [ -n ${have_grubenv} ]; then save_env recordfail; fi
insmod ext2
set root=(hd0,1)
search --no-floppy --fs-uuid --set f23b953c-f0bf-418a-8177-935671217d67
linux /boot/vmlinuz-2.6.31-14-generic root=UUID=f23b953c-f0bf-418a-8177-935671217d67 ro single
initrd /boot/initrd.img-2.6.31-14-generic
}
### END /etc/grub.d/10_linux ###

### BEGIN /etc/grub.d/20_memtest86+ ###
menuentry "Memory test (memtest86+)" {
linux16 /boot/memtest86+.bin
}
menuentry "Memory test (memtest86+, serial console 115200)" {
linux16 /boot/memtest86+.bin console=ttyS0,115200n8
}
### END /etc/grub.d/20_memtest86+ ###

### BEGIN /etc/grub.d/30_os-prober ###
menuentry "Windows NT/2000/XP (on /dev/sdb1)" {
insmod ntfs
set root=(hd1,1)
search --no-floppy --fs-uuid --set 94dc82addc8288e6
drivemap -s (hd0) ${root}
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 ###

=============================== sda1/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 defaults 0 0
# / was on /dev/sda1 during installation
UUID=f23b953c-f0bf-418a-8177-935671217d67 / ext4 errors=remount-ro 0 1
# swap was on /dev/sda5 during installation
UUID=d5e193ae-83e8-4f24-aa08-866ba4ba2a2f none swap sw 0 0
/dev/scd1 /media/cdrom0 udf,iso9660 user,noauto,exec,utf8 0 0

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


3.7GB: boot/grub/core.img
3.7GB: boot/grub/grub.cfg
.5GB: boot/initrd.img-2.6.31-14-generic
.8GB: boot/initrd.img-2.6.31-22-generic
.5GB: boot/vmlinuz-2.6.31-14-generic
.6GB: boot/vmlinuz-2.6.31-22-generic
.8GB: initrd.img
.5GB: initrd.img.old
.6GB: vmlinuz
.5GB: vmlinuz.oldI noticed that it says that GRUB2 is installed in the boot sector of sdb1(XP disk) but that core.img is missing.

Any ideas as to how this happened and hoe I can fix it?

Any help would be greatly appreciated. Thanks.

darkod
June 9th, 2010, 10:20 PM
To remove grub2 from /dev/sdb1 use this:
http://sourceforge.net/apps/mediawiki/bootinfoscript/index.php?title=Boot_Problems:Boot_Sector

So, thatīs partition #1 on disk /dev/sdb.

But I can notice you are also missing the boot.ini file for XP on /dev/sdb1. You can run the restore process booting with the XP cd and using the recovery console. However, before doing that set in BIOS /dev(sdb as first disk to boot from, because windows will install its bootloader there.

Zeppfan
June 10th, 2010, 02:49 AM
To remove grub2 from /dev/sdb1 use this:
http://sourceforge.net/apps/mediawiki/bootinfoscript/index.php?title=Boot_Problems:Boot_Sector

So, thatīs partition #1 on disk /dev/sdb.

But I can notice you are also missing the boot.ini file for XP on /dev/sdb1. You can run the restore process booting with the XP cd and using the recovery console. However, before doing that set in BIOS /dev(sdb as first disk to boot from, because windows will install its bootloader there.

OK...I did everything in your post and still getting the same error. fixboot doesn't seem to work nor does fixmbr. I downloaded and ran testdisk and ran update-grub and still nothing.

I'm stuck. Thanks for your help. Any more ideas?

darkod
June 10th, 2010, 11:09 AM
OK...I did everything in your post and still getting the same error. fixboot doesn't seem to work nor does fixmbr. I downloaded and ran testdisk and ran update-grub and still nothing.

I'm stuck. Thanks for your help. Any more ideas?

Hmmm..this is basically down to windows repairing its own boot process. If that doesn't work, the options are very limited. Even if testdisk worked to get the grub2 off the partition, XP can't work without the boot.ini.

It might be a good idea to run the script again so we can see the situation after the fixes you tried.

Zeppfan
June 10th, 2010, 02:10 PM
Hmmm..this is basically down to windows repairing its own boot process. If that doesn't work, the options are very limited. Even if testdisk worked to get the grub2 off the partition, XP can't work without the boot.ini.

It might be a good idea to run the script again so we can see the situation after the fixes you tried.

OK. Just for the heck of it, I upgraded to Lucid to see if GRUB would update and maybe fix things...NOT!!!
Here is the code from running the script again after the upgrade and everything else.


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 #1 for /boot/grub.
=> Grub 2 is installed in the MBR of /dev/sdb and looks on the same drive in
partition #1 for /boot/grub.

sda1: __________________________________________________ _______________________

File system: ntfs
Boot sector type: Grub 2
Boot sector info: Grub 2 is installed in the boot sector of sda1 and
looks at sector 275383 of the same hard drive for
core.img, but core.img can not be found at this
location. No errors found in the Boot Parameter Block.
Operating System: Windows XP
Boot files/dirs: /ntldr /ntdetect.com

sdb1: __________________________________________________ _______________________

File system: ext4
Boot sector type: Grub 2
Boot sector info: Grub 2 is installed in the boot sector of sdb1 and
looks at sector 275383 of the same hard drive for
core.img, but core.img can not be found at this
location.
Operating System: Ubuntu 10.04 LTS
Boot files/dirs: /boot/grub/grub.cfg /etc/fstab /boot/grub/core.img

sdb2: __________________________________________________ _______________________

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

sdb5: __________________________________________________ _______________________

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

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

Drive: sda ___________________ __________________________________________________ ___

Disk /dev/sda: 60.1 GB, 60060155904 bytes
255 heads, 63 sectors/track, 7301 cylinders, total 117304992 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 * 63 117,274,499 117,274,437 7 HPFS/NTFS


Drive: sdb ___________________ __________________________________________________ ___

Disk /dev/sdb: 120.0 GB, 120034123776 bytes
255 heads, 63 sectors/track, 14593 cylinders, total 234441648 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes

Partition Boot Start End Size Id System

/dev/sdb1 * 63 224,829,674 224,829,612 83 Linux
/dev/sdb2 224,829,675 234,436,544 9,606,870 5 Extended
/dev/sdb5 224,829,738 234,436,544 9,606,807 82 Linux swap / Solaris


blkid -c /dev/null: __________________________________________________ __________

Device UUID TYPE LABEL

/dev/sda1 94DC82ADDC8288E6 ntfs
/dev/sda: PTTYPE="dos"
/dev/sdb1 f23b953c-f0bf-418a-8177-935671217d67 ext4
/dev/sdb2: PTTYPE="dos"
/dev/sdb5 d5e193ae-83e8-4f24-aa08-866ba4ba2a2f swap
/dev/sdb: PTTYPE="dos"

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

Device Mount_Point Type Options

/dev/sdb1 / ext4 (rw,errors=remount-ro)


=========================== sdb1/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="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
}
insmod ext2
set root='(hd0,1)'
search --no-floppy --fs-uuid --set f23b953c-f0bf-418a-8177-935671217d67
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,1)'
search --no-floppy --fs-uuid --set f23b953c-f0bf-418a-8177-935671217d67
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,1)'
search --no-floppy --fs-uuid --set f23b953c-f0bf-418a-8177-935671217d67
linux /boot/vmlinuz-2.6.32-22-generic root=UUID=f23b953c-f0bf-418a-8177-935671217d67 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,1)'
search --no-floppy --fs-uuid --set f23b953c-f0bf-418a-8177-935671217d67
echo 'Loading Linux 2.6.32-22-generic ...'
linux /boot/vmlinuz-2.6.32-22-generic root=UUID=f23b953c-f0bf-418a-8177-935671217d67 ro single
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-2.6.32-22-generic
}
menuentry 'Ubuntu, with Linux 2.6.31-22-generic' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod ext2
set root='(hd0,1)'
search --no-floppy --fs-uuid --set f23b953c-f0bf-418a-8177-935671217d67
linux /boot/vmlinuz-2.6.31-22-generic root=UUID=f23b953c-f0bf-418a-8177-935671217d67 ro quiet splash
initrd /boot/initrd.img-2.6.31-22-generic
}
menuentry 'Ubuntu, with Linux 2.6.31-22-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod ext2
set root='(hd0,1)'
search --no-floppy --fs-uuid --set f23b953c-f0bf-418a-8177-935671217d67
echo 'Loading Linux 2.6.31-22-generic ...'
linux /boot/vmlinuz-2.6.31-22-generic root=UUID=f23b953c-f0bf-418a-8177-935671217d67 ro single
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-2.6.31-22-generic
}
### END /etc/grub.d/10_linux ###

### BEGIN /etc/grub.d/20_memtest86+ ###
menuentry "Memory test (memtest86+)" {
insmod ext2
set root='(hd0,1)'
search --no-floppy --fs-uuid --set f23b953c-f0bf-418a-8177-935671217d67
linux16 /boot/memtest86+.bin
}
menuentry "Memory test (memtest86+, serial console 115200)" {
insmod ext2
set root='(hd0,1)'
search --no-floppy --fs-uuid --set f23b953c-f0bf-418a-8177-935671217d67
linux16 /boot/memtest86+.bin console=ttyS0,115200n8
}
### END /etc/grub.d/20_memtest86+ ###

### BEGIN /etc/grub.d/30_os-prober ###
menuentry "Windows NT/2000/XP (on /dev/sdb1)" {
insmod ntfs
set root='(hd1,1)'
search --no-floppy --fs-uuid --set 94dc82addc8288e6
drivemap -s (hd0) ${root}
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 ###

=============================== sdb1/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 defaults 0 0
# / was on /dev/sda1 during installation
UUID=f23b953c-f0bf-418a-8177-935671217d67 / ext4 errors=remount-ro 0 1
# swap was on /dev/sda5 during installation
UUID=d5e193ae-83e8-4f24-aa08-866ba4ba2a2f none swap sw 0 0
/dev/scd1 /media/cdrom0 udf,iso9660 user,noauto,exec,utf8 0 0

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


.1GB: boot/grub/core.img
2.6GB: boot/grub/grub.cfg
.8GB: boot/initrd.img-2.6.31-22-generic
1.0GB: boot/initrd.img-2.6.32-22-generic
.6GB: boot/vmlinuz-2.6.31-22-generic
.8GB: boot/vmlinuz-2.6.32-22-generic
1.0GB: initrd.img
.8GB: initrd.img.old
.8GB: vmlinuz
.6GB: vmlinuz.old

I just don't know why XP will not let me fixboot or mbr. That seems to be the core of the problem.

Thanks.

darkod
June 10th, 2010, 03:06 PM
sda1: __________________________________________________ _______________________

File system: ntfs
Boot sector type: Grub 2
Boot sector info: Grub 2 is installed in the boot sector of sda1 and
looks at sector 275383 of the same hard drive for
core.img, but core.img can not be found at this
location. No errors found in the Boot Parameter Block.
Operating System: Windows XP
Boot files/dirs: /ntldr /ntdetect.com

You still have grub2 in the boot sector of the XP partition. I don't know whether it happened now during the upgrade or it was never removed.

Yes, XP not being able to repair its boot process is the core problem. And having grub2 on the partition.

You could disconnect the ubuntu disk, just to keep it safe, and try again the procedure with the XP cd to repair its boot process.

oldfred
June 10th, 2010, 06:54 PM
Windows should repair XP with the fixboot command. you have to get grub out of the windows boot sector.

To get the boot.ini back.

BOOTCFG /rebuild
http://support.microsoft.com/kb/291980
http://pcsupport.about.com/od/fixtheproblem/ht/repairbootini.htm

IF windows refuses to repair it testdisk has a rebuild capability that may work.
If Microsoft's Checkdisk (chkdsk) failed to repair the MFT, run TestDisk, also rebuild boot sector
http://www.cgsecurity.org/wiki/Advanced_NTFS_Boot_and_MFT_Repair

Zeppfan
June 12th, 2010, 12:32 AM
Windows should repair XP with the fixboot command. you have to get grub out of the windows boot sector.

To get the boot.ini back.

BOOTCFG /rebuild
http://support.microsoft.com/kb/291980
http://pcsupport.about.com/od/fixtheproblem/ht/repairbootini.htm

IF windows refuses to repair it testdisk has a rebuild capability that may work.
If Microsoft's Checkdisk (chkdsk) failed to repair the MFT, run TestDisk, also rebuild boot sector
http://www.cgsecurity.org/wiki/Advanced_NTFS_Boot_and_MFT_Repair

OK. I've tried all of the above suggestions to no avail. In fact, now when I choose to boot into XP I get a bootdisk error!!!

Great, huh? I disconnected my drive that has Lucid installed to it and did a reinstall of XP on the other drive. Still cannot boot into XP even after the reinstall. I'm really getting frustrated with this whole thing. I wouldn't even use Windows if everything would work in Ubuntu


Boot Info Script 0.55 dated February 15th, 2010

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

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

sda1: __________________________________________________ _______________________

File system: ntfs
Boot sector type: Windows XP
Boot sector info: No errors found in the Boot Parameter Block.
Operating System:
Boot files/dirs: /boot.ini /ntldr /NTDETECT.COM /NTBOOTDD.SYS

sdb1: __________________________________________________ _______________________

File system: ext4
Boot sector type: Grub 2
Boot sector info: Grub 2 is installed in the boot sector of sdb1 and
looks at sector 275383 of the same hard drive for
core.img, but core.img can not be found at this
location.
Operating System: Ubuntu 10.04 LTS
Boot files/dirs: /boot/grub/grub.cfg /etc/fstab /boot/grub/core.img

sdb2: __________________________________________________ _______________________

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

sdb5: __________________________________________________ _______________________

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

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

Drive: sda ___________________ __________________________________________________ ___

Disk /dev/sda: 60.1 GB, 60060155904 bytes
255 heads, 63 sectors/track, 7301 cylinders, total 117304992 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 * 63 117,274,499 117,274,437 7 HPFS/NTFS


Drive: sdb ___________________ __________________________________________________ ___

Disk /dev/sdb: 120.0 GB, 120034123776 bytes
255 heads, 63 sectors/track, 14593 cylinders, total 234441648 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes

Partition Boot Start End Size Id System

/dev/sdb1 * 63 224,829,674 224,829,612 83 Linux
/dev/sdb2 224,829,675 234,436,544 9,606,870 5 Extended
/dev/sdb5 224,829,738 234,436,544 9,606,807 82 Linux swap / Solaris


blkid -c /dev/null: __________________________________________________ __________

Device UUID TYPE LABEL

/dev/sda1 B288DE7288DE3517 ntfs
/dev/sda: PTTYPE="dos"
/dev/sdb1 f23b953c-f0bf-418a-8177-935671217d67 ext4
/dev/sdb2: PTTYPE="dos"
/dev/sdb5 d5e193ae-83e8-4f24-aa08-866ba4ba2a2f swap
/dev/sdb: PTTYPE="dos"

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

Device Mount_Point Type Options

/dev/sdb1 / ext4 (rw,errors=remount-ro)


================================ sda1/boot.ini: ================================

[boot loader]
timeout=1
default=signature(f08af08a)disk(0)rdisk(0)partitio n(1)\WINDOWS
[operating systems]
signature(f08af08a)disk(0)rdisk(0)partition(1)\WIN DOWS="Microsoft Windows XP Home Edition" /noexecute=optin /fastdetect

=========================== sdb1/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="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
}
insmod ext2
set root='(hd1,1)'
search --no-floppy --fs-uuid --set f23b953c-f0bf-418a-8177-935671217d67
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='(hd1,1)'
search --no-floppy --fs-uuid --set f23b953c-f0bf-418a-8177-935671217d67
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='(hd1,1)'
search --no-floppy --fs-uuid --set f23b953c-f0bf-418a-8177-935671217d67
linux /boot/vmlinuz-2.6.32-22-generic root=UUID=f23b953c-f0bf-418a-8177-935671217d67 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='(hd1,1)'
search --no-floppy --fs-uuid --set f23b953c-f0bf-418a-8177-935671217d67
echo 'Loading Linux 2.6.32-22-generic ...'
linux /boot/vmlinuz-2.6.32-22-generic root=UUID=f23b953c-f0bf-418a-8177-935671217d67 ro single
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-2.6.32-22-generic
}
menuentry 'Ubuntu, with Linux 2.6.31-22-generic' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod ext2
set root='(hd1,1)'
search --no-floppy --fs-uuid --set f23b953c-f0bf-418a-8177-935671217d67
linux /boot/vmlinuz-2.6.31-22-generic root=UUID=f23b953c-f0bf-418a-8177-935671217d67 ro quiet splash
initrd /boot/initrd.img-2.6.31-22-generic
}
menuentry 'Ubuntu, with Linux 2.6.31-22-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod ext2
set root='(hd1,1)'
search --no-floppy --fs-uuid --set f23b953c-f0bf-418a-8177-935671217d67
echo 'Loading Linux 2.6.31-22-generic ...'
linux /boot/vmlinuz-2.6.31-22-generic root=UUID=f23b953c-f0bf-418a-8177-935671217d67 ro single
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-2.6.31-22-generic
}
### END /etc/grub.d/10_linux ###

### BEGIN /etc/grub.d/20_memtest86+ ###
menuentry "Memory test (memtest86+)" {
insmod ext2
set root='(hd1,1)'
search --no-floppy --fs-uuid --set f23b953c-f0bf-418a-8177-935671217d67
linux16 /boot/memtest86+.bin
}
menuentry "Memory test (memtest86+, serial console 115200)" {
insmod ext2
set root='(hd1,1)'
search --no-floppy --fs-uuid --set f23b953c-f0bf-418a-8177-935671217d67
linux16 /boot/memtest86+.bin console=ttyS0,115200n8
}
### END /etc/grub.d/20_memtest86+ ###

### BEGIN /etc/grub.d/30_os-prober ###
menuentry "Windows NT/2000/XP (loader) (on /dev/sda1)" {
insmod ntfs
set root='(hd0,1)'
search --no-floppy --fs-uuid --set b288de7288de3517
drivemap -s (hd0) ${root}
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 ###

=============================== sdb1/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 defaults 0 0
# / was on /dev/sda1 during installation
UUID=f23b953c-f0bf-418a-8177-935671217d67 / ext4 errors=remount-ro 0 1
# swap was on /dev/sda5 during installation
UUID=d5e193ae-83e8-4f24-aa08-866ba4ba2a2f none swap sw 0 0
/dev/scd1 /media/cdrom0 udf,iso9660 user,noauto,exec,utf8 0 0

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


.1GB: boot/grub/core.img
.3GB: boot/grub/grub.cfg
.8GB: boot/initrd.img-2.6.31-22-generic
1.0GB: boot/initrd.img-2.6.32-22-generic
.6GB: boot/vmlinuz-2.6.31-22-generic
.8GB: boot/vmlinuz-2.6.32-22-generic
1.0GB: initrd.img
.8GB: initrd.img.old
.8GB: vmlinuz
.6GB: vmlinuz.oldEverything looks good as far as I can see. Is the testdisk supposed to be there? If not, how do I get rid of it?

.

Thanks guys for all the help so far.

darkod
June 12th, 2010, 12:43 AM
No, testdisk is not supposed to be on the MBR of /dev/sda. At least not in general. Also the boot file ntbootdd.sys shouldn't be there. I guess that's some result of the testdisk procedure.

Were you trying anything with testdisk also after reinstalling XP? The XP installed would have wiped testdisk off the MBR so I'm very surprised to see it there.

Zeppfan
June 12th, 2010, 12:48 AM
Honestly, I don't remember if I tried testdisk after the reinstall of XP. I do know that after the reinstall, I got the diskboot failure error. That was before I reconnected the Ubuntu HDD.

darkod
June 12th, 2010, 01:03 AM
It probably sounds like a broken record, but unplug your ubuntu disk again, boot with XP cd, go into Recovery Console and do again:

fixboot c:
fixmbr

Restart and see whether XP will boot. You can also boot with the ubuntu cd in live mode and run the script again. testdisk should be gone from the MBR and also the ntbootdd.sys file.

Zeppfan
June 12th, 2010, 01:05 AM
Will try it.