# BTX Halted when trying to boot memstick img



## jstn (Dec 30, 2018)

Hi all. IRC was stumped so I came here and made an account to get some more visibility on this issue. I am attempting to install FreeBSD on my older homebuilt desktop computer and I keep getting this "BTX Halted" error immediately on boot: https://i.imgur.com/JptVTdq.jpg

The machine in question has an MSI p55-gd55 motherboard and an Intel i5-750, 16GB RAM. I have tried 12.0-RELEASE, 12.0-STABLE, and 13.0-CURRENT all with the same results. I've used the same stick to boot various Linux isos on this machine and others recently with no issues.  I am writing the usb stick on a Void Linux (running Musl libc although I don't think that matters) machine with dd if=[memstick.img] of=/dev/sdb bs=1M conv=sync as per the documentation. I also tried each of these with bs=10240 since I came across another forum post for the same issue that was solved that way, but no dice there either.

Any ideas to get past this? I've been running FreeBSD in a VM for the last few days and I really want to switch over to it permanently.


----------



## Vull (Dec 30, 2018)

Might be worth a try installing 11.2-RELEASE, which is still supported, very well-tested, widely-used, and arguably the most reliable and "stable" version currently in use.


----------



## twllnbrck (Dec 30, 2018)

Which iso did you use to create your bootstick?


----------



## jstn (Dec 30, 2018)

I'm using the *memstick.img files - all of the ones I've tried have given the same result.

I would burn a disc but this box doesn't have any optical drives.


----------



## Sevendogsbsd (Dec 30, 2018)

Interesting - I have actually never used the memstick images, only the "boot only" or "disc1" isos. I write them to a thumb drive using `dd` and have never had an issue. Is this the only OS on this system? Is the system EFI or BIOS?


----------



## jstn (Dec 30, 2018)

It's a BIOS system (like I said it's a somewhat old machine). It does have Windows 10 installed on it, but that has it's own disk which I'm not touching at all here. There is a 222GB SSD I'm trying to install to, and then a handful of 1TB platter drives one of which has Win10 on it.

On a whim I threw OpenBSD on there and it boots and installs just fine, but I can't really use that since I have an Nvidia card here and there's no way to get native resolution with that in oBSD.

Anyway I'll try writing the disc1 iso and see if that boots. If that doesn't work I'll try 11.2 like the other guy said - I'm guessing if I got that installed I could upgrade to 12.0 from there?


----------



## tingo (Dec 30, 2018)

I usually just use `# dd if=memstick.img of=/dev/da0 bs=4M` when I write images to memory sticks. Substitute /dev/da0 with the real device you're writing to of course. The bs= parameter usually only affects speed when writing to usb sticks (for other media types it might need to be correct). These days, I usually only use the memstick images when installing FreeBSD. 
If you are sure the images are not corrupted, try a different usb stick. If that doesn't work, try a different machine or a different os on the machine you have. Given enough usb ports it is possible to boot a machine from a usb memory stick with a "live" OS, and using that to write another usb stick with a memstick image.


----------



## jstn (Dec 30, 2018)

The USB stick in question has booted several different OS's on several different machines recently so I'm fairly confident there's nothing wrong with it.  In any case I don't have any other ones (I know I know, they're cheap, I just haven't needed one in a while so I don't have any around).

Interestingly though the 11.2-STABLE memstick img boots just fine, so I'm going to move forward with installing that and then see if I can manage to upgrade from there. Still wondering why none of the other images will boot on my hardware but this should at least get the box up and running.


----------



## Sevendogsbsd (Dec 30, 2018)

Personally, if this is a "production" machine or a desktop you rely on, I would avoid any "STABLE" or "CURRENT" versions, but I am pretty conservative about what I run.


----------



## free-and-bsd (Dec 30, 2018)

For some reason USB-targeted ISOs never — NEVER!— worked for me. So what I usually do is format my USB stick in 2 partitions. Install GRUB2 onto one of them, then dd-write the CD-image (not memstick-image, mind you ) on the other one that's made about the size of that CD-image.

This is best done on a Linux distro, just as you did. Formatting the USB tips can be found here at https://www.pendrivelinux.com/boot-multiple-iso-from-usb-via-grub2-using-linux. But DON'T use GRUB to boot a FreeBSD ISO though, just use the instructions to format your USB stick and install GRUB2 there. Only, you make a small (or big) partition for GRUB stuff, then add another one where you will dd-write your CD-image.

With this done you just add the simple syntax for GRUB to boot from that CD-written partition:
menuentry 'FreeBSD CD' {
set root=(hd0,msdos1)
kfreebsd /boot/loader
}


----------



## free-and-bsd (Dec 30, 2018)

BTW, this way I always boot the next RELEASE CD by just dd-writing it to the partition. I know, it looks crazy, but...


----------



## _martin (Dec 30, 2018)

This has nothing do to with the memstick version of FreeBSD. Unfortunately this is a bug introduced in 12.0 when part of the bootloader was rewritten. You can find other threads where this issue is discussed, e.g. also here. I also opened PR for this. I was disappointed that it didn't get to errata at least as more users have this issue. Maybe not enough people are complaining (not here, but officially by either submitting PR or sending mails to mailing lists).

12-STABLE has this issue fixed. Or at least I was able to boot with it. I was considering using /boot from 12-STABLE and everything else from 12-RELENG (I'm using svn) but after other issues I've decided I have 0 benefit from 12 and booted back to 11.2 for now.

Now as you're saying you can't boot it off even from 12-stable and 13, I suggest you reply to my PR so guys are aware of this.


----------



## free-and-bsd (Dec 30, 2018)

_martin said:


> This has nothing do to with the memstick version of FreeBSD.


Sorry, I seem to have answered to my own thoughts  But that's true, the memstick image never worked for me — though unrelated to this topic here.


----------



## Sevendogsbsd (Dec 30, 2018)

Interesting - I boot and install fine off a 12.0-RELEASE bootonly iso written to a thumbdrive. Maybe I am just lucky?


----------

