Run FreeBSD from USB stick

Hi all,

It seems I'm coming back to FreeBSD after about 5 years break (I used FreeBSD from 1998 until about 2006, but due to certain reasons other OS after that). Anyway, I'm thinking about building a home NAS server. There is a great chance that I'll be using FreeBSD for that as I want to use zfs and also want to use this machine as domain controller to do user authentication and store user profiles on this machine. The setup I want to do is pretty simple: some low power Intel motherboard with G620T CPU or something like that, "green" and silent PSU. I already have RAM and disks from other home PCs. It sounds all simple and I would not have a problem if I would not want to run FreeBSD from USB memory stick.

I read half the internet and could see that others were successful with running FreeBSD from a thumb drive, but I was not so lucky. The most I got is when PC boots from USB (MBR or boot loader) and when it reaches the step when it mounts root partition from the USB it pukes with error 19. :(

I'm wondering if there is a step by step guide on how to install FreeBSD to USB thumb drive so it'll boot properly.

I would appreciate any help, and once everything is working, I'll publish a guide on how to build a NAS with such configuration since I did not find one.

Thanks in advance!
 
andyzammy said:
Is there any reason you need to register to read this? I don't mind doing so if I'm sure I won't get spam.

The only mails I get from them are monthly reminders that a new issue is available for download.

You can always use fake/temporary account when in doubt.
 
I'm running my FreeBSD NAS from a USB stick, having successfully tried with a dedicated bsdlabel and currently with a GPT label. My setup just boots, loads the kernel and modules from the stick, then mounts the root filesystem from a whole-disk ZFS pool.

There's no reason why the root filesystem couldn't be on the stick as well though.

You can find some of my info here.
 
Am I missing something in the BSD article about installing the FreeBSD OS on a memstick, because I'm not seeing the details of whats involved. It mentions page 36 has information on making a bootable USB, but when you click or go to that page, it doesn't speak on that.
 
The standard install should work on a USB stick. However, it can take USB devices a few seconds to be recognized, sometimes too later after the kernel looks for a disk to boot. To give a longer timeout:
/boot/loader.conf:
Code:
kern.cam.boot_delay=10000
kern.cam.scsi_delay=10000
 
Back
Top