Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 30 Jan 2005 09:04:20 +0000
From:      Joe Kraft <hishadow@netcabo.pt>
To:        freebsd-questions@freebsd.org
Subject:   Re: Booting FreeBSD-5.3 from NTLDR
Message-ID:  <41FCA314.3070602@netcabo.pt>
In-Reply-To: <38b3f6e4050129231132f8e743@mail.gmail.com>
References:  <38b3f6e40501292247696b96b@mail.gmail.com> <38b3f6e4050129231132f8e743@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Rakhesh Sasidharan wrote:
> I didnt see a copy of this mail returned to me, so am sure if it has
> reached the list. Since I just subscribed, its possible something is
> wrong -- and so am resending it.
> 
> Sorry for the inconv. :)) 
> 
> On Sun, 30 Jan 2005 10:47:41 +0400, Rakhesh Sasidharan
> <rakhesh.s@gmail.com> wrote:
> 
>>Hi,
>>
>>Are there any issues in booting FreeBSD using NTLDR? My machine has
>>Windows XP, Fedora Core 3, and FreeBSD-5.3, and while I know I can use
>>GRUB to boot FreeBSD, I want to try booting it using NTLDR. Just for
>>kicks -- its something I haven't tried so far. :))
>>
>>My ad0 disk has WinXP (and NTLDR), while ad1 has FreeBSD. I tried the
>>usual suggestions of extracting the first 512 bytes of "/dev/ad1"
>>(using "dd") into a file and telling NTLDR to use that file for
>>booting. But it doesn't work. Then I tried extracting 512 bytes from
>>other locations like "/dev/ad1s1" and "/dev/ad1s1a" and "/dev/ad1s1c",
>>but to no avail. Finally I even tried copying over copying
>>"/boot/boot1" (and even "/boot/boot2" and "/boot/loader" coz I was at
>>my wits end) to a file, and telling NTLDR to use that file for booting
>>-- but again nada! Most of the times I'd get a "Boot Error" message,
>>while at other times nothing happens.
>>
>>Searching around on Google, I found a post to freebsd-stable that asks
>>the same question
>>(http://www.mail-archive.com/freebsd-stable@freebsd.org/msg64950.html).
>>The reply given there was to use this program called BOOTPART (can be
>>run from Windows, it extracts the bootsector of any partition you
>>specify, which can then be used to boot into that partition using
>>NTLDR). Using that program does allow me extract the bootsectors of
>>the FreeBSD partition, and use that from NTLDR to boot into it -- but
>>I am still stumped -- how does this program manage to extract the
>>bootsectors, while "dd" is not? I've used the "dd" method to
>>successfully boot into Fedora Core 3 using NTLDR, so I know it
>>generally does the job.
>>
>>Any suggestions folks? Is there some incompatibility thing with NTLDR,
>>or am I going wrong somewhere?
>>
>>Thanks,
>>Rakhesh
>>
> 
> 
> 

I'm doing it with Win2k, I haven't tried it yet with XP though.  And 
I'll preface this, with I'm doing this from memory because I can't find 
the web page they originally came from.

I had Win2k set up already with an empty partition for FBSD.  A fresh 
backup of the windows part, and the magic "recovery disk" may ease 
concerns of trashing what you have, but I like to live dangerously so I 
didn't have them.

Boot the FBSD install CD and install, when you're setting up the 
partition I've tried to get the installer to leave the boot loader 
alone, but NTLDR gets clobbered every time.

When you've got FBSD running, save a copy of /boot/boot0 somewhere you 
will be able to get to it from Windows.

Now you've bot FBSD but not windows, now go back to your Win2k install 
CD and "repair" your current installation, all you should have do do is 
the 'inspect boot files" part.

Once windows restarts, as "administrator" you need to edit boot.ini to 
add an entry for FBSD.  Mine looks like (the last line wrapped, but 
should be a single line):

[root@slug mnt]# cat boot.ini
[boot loader]
timeout=10
default=C:\freebsd.boot
[operating systems]
C:\freebsd.boot="FreeBSD"
multi(0)disk(0)rdisk(0)partition(1)\WINNT="Microsoft Windows 2000 
Professional" /fastdetect

Then copy the boot0 file to C: drive (I called it freebsd.boot). 
Restart the computer and you should have two choices in the list and you 
can choose to boot windows or FBSD.

Best of luck,
Joe.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?41FCA314.3070602>