Installing FreeBSD from USB flash drive - some experiments
doconnor at gsoft.com.au
Tue Mar 10 21:11:06 PDT 2009
On Wednesday 11 March 2009 13:55:58 Clifton Royston wrote:
> I think I have found some limitations of the current sysinstall which
> currently make it currently difficult to convert a working FreeBSD ISO
> to an installable or live-disk flash image. Booting the kernel is
> easy. Getting the rest of the way is harder.
I have a working USB installer for 7.1 but it is not terribly straightfoward.
> Background: AFAICT the release ISOs don't currently mount the media
> they were booted from (da0a in this case.) Instead they load
> boot/mfsroot.gz (compressed memory image) as the root fs, which is fine
> and makes good sense, but they don't then mount the boot media anywhere
> under it. (My guess is that this was probably originally done to
> support the floppy boot case.)
Yes, I think so.
> So how can you direct it to install from the USB media?
> 1) If you try to select media via the menu options, you can't select
> USB specifically, nor specify an arbitrary device as the source
> (/dev/da0a in this case), so you can't get the booted medium mounted to
> install from, so you can't get the distributions accessible, so install
> doesn't work. Picking CD as the media seems to mean specifically an
> cd or acd device.
For some reason the "Install from UFS" thing doesn't let you mount anything, I
think this would be fairly easy to fix.
I didn't actually attempt to fix this, instead I split my USB stick in 2. The
first partition was 2.5Gb FAT32, the last 1.5Gb was UFS. I put the CD image on
there and did boot0cfg etc..
The reason FAT goes first is that otherwise when you put it into a Windows PC
(as I'd like people to be able to do to edit the install.cfg) Windows gets
confused and wants to format the disk.. Putting UFS last gets around this and
it still works fine.
> 5) "The emergency holographic shell, then?" Yes, you can get into
> the emergency holographic shell, with the very limited set of commands
> from the mfsroot bin/sbin/stand. However, if you try using the
> emergency holographic shell to mount da0a - as far as I can tell, you
> can't do so, because there is no mount in mfsboot's stand, only
> mount_nfs. (I'm guessing the "mount" operation for acd0 or cd0 is
> coded into sysinstall?) The usual mount command of course exists on the
> media, but it's on the LiveCD portion which isn't mounted at this
Yeah, the lack of mount in /stand on the install disk is a big caveat.
I suspect you could go into label and add /dev/da0a (also, argh, DD is bad,
use an MBR) and tell it not to newfs it and then sysinstall will mount it for
Daniel O'Connor software and network engineer
for Genesis Software - http://www.gsoft.com.au
"The nice thing about standards is that there
are so many of them to choose from."
-- Andrew Tanenbaum
GPG Fingerprint - 5596 B766 97C0 0E94 4347 295E E593 DC20 7B3F CE8C
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 189 bytes
Desc: This is a digitally signed message part.
Url : http://lists.freebsd.org/pipermail/freebsd-stable/attachments/20090311/71b77682/attachment.pgp
More information about the freebsd-stable