Re: BTX on USB pen drive



On Sat, Mar 08, 2008 at 10:21:45PM +0100, Torfinn Ingolfsen wrote:
On Sat, 08 Mar 2008 14:23:30 +0100
Dimitry Andric <dimitry@xxxxxxxxxx> wrote:

No, update it to 1.45 (=HEAD) and then apply the patch, that's much
easier.

Yes, that worked better - the patch applied cleanly, amd I could
rebuild the loader.

Here is how I did the rebuilding (all this done on another machine,
which have no troubles booting from usb):
I booted the machine from usb (da0), replaced btx.S with revision 1.45
and did:
cd /usr/src
patch -p6 < .../btx_real.patch
cd sys/boot/i386
make
Then I copied the files to the hard drive:
boot0cfg -B -b /usr/obj/usr/src/sys/boot/i386/boot0/boot0 da0
cp -v /usr/obj/usr/src/sys/boot/i386/loader/loader /boot

Is this the correct way to do build and update the files?

To quote lolcats: "yr doin it wrong".

The Handbook goes over how to rebuild the bootblocks. See Section
24.6.5.2, which is for Serial Console. You can skip the obvious steps
(items 1-3, and item 5). Patch the source *before* doing item 4,
obviously:

http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/serialconsole-setup.html

There's a lot of pieces involved when it comes to BTX; all stages
(boot0, boot1, boot2/loader) appear to use the BTX library in
src/sys/boot/i386/btx/lib. Thus, following the procedure above is the
right way to do things.

Your boot0cfg line to reinstall the boot0 MBR looks fine, but I don't
use boot0 myself (I prefer to go right into boot2/loader).

--
| Jeremy Chadwick jdc at parodius.com |
| Parodius Networking http://www.parodius.com/ |
| UNIX Systems Administrator Mountain View, CA, USA |
| Making life hard for others since 1977. PGP: 4BD6C0CB |

_______________________________________________
freebsd-stable@xxxxxxxxxxx mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "freebsd-stable-unsubscribe@xxxxxxxxxxx"



Relevant Pages

  • Re: XP Pro install problem with USB mouse
    ... been intending to rebuild the recalcitrant beast for some weeks now. ... it's the USB variety and I hadn't ... the PC rebooted and fired up Windows to continue the installation, ... After several reboots, ...
    (alt.os.windows-xp)
  • Re: BTX on USB pen drive
    ... rebuild the loader. ... I booted the machine from usb, ... I as because when I moved the usb hard drive to the problematic laptop ... text scrolls forever on screen. ...
    (freebsd-stable)
  • Re: USB mouse problems
    ... other USB ports are working fine (I also have an USB keyboard plugged ... Lachesis doesn't work with FreeBSD. ... You'll have to rebuild ...
    (freebsd-questions)