LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
Search this Thread
Old 06-29-2008, 09:38 AM   #1
5n0wCr@5h
LQ Newbie
 
Registered: Jun 2008
Posts: 3

Rep: Reputation: 0
Booting WIN XP via grub: Invalid or unsupported executable format


Hello and want to extend my appreciation in advance. I checked the other thread re: Vista but that solution and many permutations teszted are not working so I will explain my setup:

Dell Laptop E1505 with WindowsXP.

successful install of fd8 on 60BG fujitsu usb drive.

When I try to boot WindowsXP I receive the above Error 13.

#fdisk -l

/dev/sdb1 1 6 de dell util
/dev/sdb2 12 6693 7 HPFS/NTFS
/dev/sdb3 6694 8939 7 HPFS/NTFS
/dev/sdb4 8940 9545 db CPM/CTOS


/dev/sda1 1 25 83 Linux
/dev/sda2 26 7296 8e Linux LVM


Disk /dev/dm-0 57.6 GB (I believe is laptop c drive)
...
Disk /dev/dm-0 doesn't contain a valid partition table

Disk /dev/dm-1 20.8 GB (laptop d: drive)
Disk /dev/dm-1 doesn't contain a valid partition table

Device.map

(hd1) /dev/sda
(hd0) /dev/sdb

#df -h
53G 2.1G 51G 4% /
/dev/sda1 190m 13m 168m 7% /boot
tmpfs 501m /dev/shm
/dev/sdb3 18G 12G 33% /media/backup
/dev/sdb2 52G 79% /media/disk


grub.conf


#boot=/dev/sdb
default=0
timeout=12
splashimage=(hd0,0)/grub/splash.xpm.gz
hiddenmenu
password --md5 $1$OY8g7UUS$.tL.ruU61EsFnH/EN4XzM.
title Fedora (2.6.25.6-27.fc8)
root (hd0,0)
kernel /vmlinuz-2.6.25.6-27.fc8 ro root=/dev/VolGroup00/LogVol00 rhgb quiet
initrd /initrd-2.6.25.6-27.fc8.img
title Fedora (2.6.21.7-3.fc8xen)
root (hd0,0)
kernel /xen.gz-2.6.21.7-3.fc8
module /vmlinuz-2.6.21.7-3.fc8xen ro root=/dev/VolGroup00/LogVol00 rhgb quiet
module /initrd-2.6.21.7-3.fc8xen.img
title Fedora (2.6.21-2950.fc8xen)
root (hd0,0)
kernel /xen.gz-2.6.21-2950.fc8
module /vmlinuz-2.6.21-2950.fc8xen ro root=/dev/VolGroup00/LogVol00 rhgb quiet
module /initrd-2.6.21-2950.fc8xen.img
title Fedora-base (2.6.23.1-42.fc8)
root (hd0,0)
kernel /vmlinuz-2.6.23.1-42.fc8 ro root=/dev/VolGroup00/LogVol00 rhgb quiet
initrd /initrd-2.6.23.1-42.fc8.img
#title WindowsXP
# rootnoverify (hd1,1)
# chainloader +1
title WindowsXP
# hide (hd0,0)
# rootnoverify (hd1,0)
# map (hd0) (hd1)
# map (hd1) hd0)
rootnoverify (hd0,1)
makeactive
chainloader +1

Error 13....(when trying to boot Windows only) All Linux/Xen boot fine.

I suspect the above fdisk output:

Disk /dev/dm-0 doesn't contain a valid partition table

Disk /dev/dm-1 doesn't contain a valid partition table

is the issue?? Need bigtime help with this one.


Note: Originally, during installation of fd8 I moved the bootloader back to the laptop HD. This worked [only] once??? ie I was able to boot WindowsXP so I reinstalled fd8 and moved boot loader back to usb but lost ability to boot XP. I would not care but have thousands of $ of software and development installed and very poor hence move to Linux.

Last edited by 5n0wCr@5h; 06-29-2008 at 10:24 AM. Reason: clarifying post
 
Old 06-30-2008, 05:43 AM   #2
Larry Webb
LQ Veteran
 
Registered: Jul 2006
Location: Crystal Beach, Texas
Distribution: Suse for mail +
Posts: 5,100
Blog Entries: 7

Rep: Reputation: 229Reputation: 229Reputation: 229
If you have not changed anything since fdisk -l above try to edit the bottom windows entry in your grub.conf file. Remove the entry rootnoverify (hd0,1) and see if your windows will boot.
 
Old 06-30-2008, 05:45 AM   #3
JZL240I-U
Senior Member
 
Registered: Apr 2003
Location: Germany
Distribution: openSuSE 13.1 / 12.3_64-KDE, Ubuntu 14.04, Fedora 20, Mint 17, Chakra
Posts: 3,642

Rep: Reputation: Disabled
Well, from your menu.lst I'd guess a simple answer: put these two lines back in
Code:
map (hd0) (hd1)
map (hd1) (hd0)
i.e. uncomment them. Last time I looked, Windows insisted to be installed on the first partition of the first disk (= /dev/sda1). In your setup linux is there...

Last edited by JZL240I-U; 07-02-2008 at 01:28 AM. Reason: added missing "(" in the line map (hd1) hd0)
 
Old 06-30-2008, 05:57 AM   #4
Larry Webb
LQ Veteran
 
Registered: Jul 2006
Location: Crystal Beach, Texas
Distribution: Suse for mail +
Posts: 5,100
Blog Entries: 7

Rep: Reputation: 229Reputation: 229Reputation: 229
Thanks I missed the map lines being uncommented and the rootnoverify (hd1,0)
 
Old 07-01-2008, 05:29 PM   #5
5n0wCr@5h
LQ Newbie
 
Registered: Jun 2008
Posts: 3

Original Poster
Rep: Reputation: 0
Put map lines back in --> Error

Thank you very much for your help!!!

I put the two map lines back in:

map (hd0) (hd1)
map (hd1) (hd0)

Error 11, Unrecognized device string immediately after those two lines.

I also used:

title windowsxp
rootnoverify (hd1,1)
chainloader +1

and

title windowsxp
rootnoverify (hd1,0)
chainloader +1

and


map (hd0,0) (hd0,2)
map (hd0,2) (hd0,0)
rootnoverify (hd0,2)
chainloader +1

# Unrecognized device string

and


rootnoverify (hd0,2)
chainloader +1

#Invalid or unsupportable executable format

and

rootnoverify (hd0,1)
makeactive
chainloader +1

# Invalid or unsupportable executable format
 
Old 07-01-2008, 05:49 PM   #6
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 12,042

Rep: Reputation: 970Reputation: 970Reputation: 970Reputation: 970Reputation: 970Reputation: 970Reputation: 970Reputation: 970
Try this (make sure the spaces are there for the "map" directives)
Code:
title WindowsXP
rootnoverify (hd1,1)
map (hd0) (hd1)
map (hd1) (hd0)
makeactive
chainloader +1

Last edited by syg00; 07-02-2008 at 01:41 AM. Reason: corrected as per post #9 below
 
Old 07-01-2008, 07:40 PM   #7
5n0wCr@5h
LQ Newbie
 
Registered: Jun 2008
Posts: 3

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by syg00 View Post
Try this (make sure the spaces are there for the "map" directives)
Code:
title WindowsXP
rootnoverify (hd1,1)
map (hd0) (hd1)
map (hd1) hd0)
makeactive
chainloader +1
You rock syg00. Don't know what to say other than...[very] impressive. Please explain when you have a minute.
 
Old 07-01-2008, 08:33 PM   #8
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 12,042

Rep: Reputation: 970Reputation: 970Reputation: 970Reputation: 970Reputation: 970Reputation: 970Reputation: 970Reputation: 970
Windows (being brain-dead) needs to be on the first (BIOS boot) disk. I prefer to leave it that way for convenience - Linux is flexible enough to handle any setup. Some of the installers are a bit limited, but that's the fault of the particular distro devs, *not* Linux itself.
With your arrangement you need to con Windows into thinking it actually is on the first disk - hence the "map" directives; that's grub doing the "fudging" for you. The makeactive is really not needed but does no harm as Windows also expect the boot/active flag to be on.

Plenty of info on the grub site - here.

Last edited by syg00; 07-01-2008 at 08:34 PM.
 
Old 07-02-2008, 01:31 AM   #9
JZL240I-U
Senior Member
 
Registered: Apr 2003
Location: Germany
Distribution: openSuSE 13.1 / 12.3_64-KDE, Ubuntu 14.04, Fedora 20, Mint 17, Chakra
Posts: 3,642

Rep: Reputation: Disabled
For any late or newcomers: the second map line misses a "(" in the second map argument, it should read
Code:
map (hd1) (hd0)
syg00 Why "rootnoverify (1,0)"? Could you comment on that, I simply don't get it why you set the LVM volume to root ...
 
Old 07-02-2008, 01:48 AM   #10
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 12,042

Rep: Reputation: 970Reputation: 970Reputation: 970Reputation: 970Reputation: 970Reputation: 970Reputation: 970Reputation: 970
Thanks @JZL240I-U; fixed above.
Nope, that's the Windoze disk - when in doubt, trust the (working) config. If Linux successfully boots from a root(hd0,0), the other disk must be hd1. Simple.
And yes, I did see the device.map. And nope, I can't explain it any better without playing around on the box itself.
 
Old 07-07-2008, 03:45 AM   #11
JZL240I-U
Senior Member
 
Registered: Apr 2003
Location: Germany
Distribution: openSuSE 13.1 / 12.3_64-KDE, Ubuntu 14.04, Fedora 20, Mint 17, Chakra
Posts: 3,642

Rep: Reputation: Disabled
Quote:
Originally Posted by syg00 View Post
...Nope, that's the Windoze disk - when in doubt, trust the (working) config...
Oops, right. My bad. Thanks for the explanation. See (read) you.
 
  


Reply

Tags
boot, boot loader, dual


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Error 13: Invalid or unsupported executable format + solaris and linux lsanga099 Linux - Newbie 4 06-30-2008 07:10 AM
GRUB error: Invalid or unsupported executable format newtovanilla Linux - Newbie 4 04-29-2008 02:14 PM
[SOLVED] Booting Vista via grub: Invalid or unsupported executable format jot Linux - Kernel 3 01-07-2007 04:03 AM
xen installation error: error 13: invalid or unsupported executable format Niceman2005 Linux - Software 0 01-05-2007 01:51 AM
kernel 2.6.3 compile ends in grub error 13: unsupported executable format(?) browny_amiga Linux - General 4 03-06-2004 02:33 PM


All times are GMT -5. The time now is 07:16 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration