bootable FreeBSD on USB-Flash-Drive [SOLUTION] ???

2008-08-25 Thread Matthias Apitz

Hello,

It is relatively easy to produce a FreeBSD 7.0 booting USB key (for
example for the installation of FreeBSD 7.0 if the target machine has no
CD but only USB externals), if one follow more or less the description in
http://groups.google.com/group/lucky.freebsd.questions/msg/5c759b1c87376b22

I said 'more or less' because the problem is that the procedure at
certain point assumes that you have the installation data (which is on
FreeBSD CD1) accessible, but you have at this moment the LifeFS CD
mounted);

I helped myself doing the process based on my running FreeBSD 7.0
laptop, mounted the CD1 and built the USB key.

I'm asking me (and all) how this could be done having only the FreeBSD
7.0 CDs and no running FreeBSD 7.0 system?

Thx

matthias
-- 
Matthias Apitz
Manager Technical Support - OCLC GmbH
Gruenwalder Weg 28g - 82041 Oberhaching - Germany
t +49-89-61308 351 - f +49-89-61308 399 - m +49-170-4527211
e [EMAIL PROTECTED] - w http://www.oclc.org/ http://www.UnixArea.de/
b http://gurucubano.blogspot.com/
We should all learn from the peoples of The Netherlands, France and Ireland.
Aprendamos todos de los pueblos de Holanda, Francia e Irlanda.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


bootable FreeBSD on USB-Flash-Drive [SOLUTION]

2006-03-31 Thread Grossmann Martin
a little success story with freebsd and a tiny usb stick:
[tried with FreeBSD 6.1-BETA4 install-cd and a kingston 256MB
usb-flash-drive]

prepare yourself to work on the command-line ;-)
- attach the usb-stick to the server
- boot the freebsd installation cd-rom
- go to the fixit shell
- CHECK YOUR DMESG WHAT DEVICE YOUR USB STICK ACTUALLY IS!!! (here /dev/da0)

create the future /-filesystem on your usb-drive:

wipe everything on the usb-drive:
# dd if=/dev/zero of=/dev/da0 bs=1m
create a new partition table on it with a default slice 1 and make it
bootable
# fdisk -BI /dev/da0
label it for booting freebsd:
# bsdlabel -wB /dev/da0s1
you'll have to edit the disklabel (sometimes you'll have to: # export
EDITOR=/mnt2/usr/bin/vi):
# bsdlabel -e /dev/da0s1
... and change partition a from unused to 4.2BSD as partition type
create the future / a.k.a. root-filesystem on it:
# newfs -m 0 -o space /dev/da0s1a

mount the filesystem for installation:
# mount /dev/da0s1a /mnt

install freebsd on /mnt:
# export DESTDIR=/mnt
# cd /dist/RELEASENAMEHERE
# for i in base manpages catpages
# do
#   cd $i; echo y|./install.sh; cd ..;
# done

go to the kernels directory and install a kernel of your choice:
[default is GENERIC kernel; change to smp for smp-machines]
# rmdir /mnt/boot/kernel
# cd kernels;
# cat generic.??|tar --unlink -xpzf - -C /mnt/boot
# cd /mnt/boot  mv GENERIC kernel

now, tell freebsd to mount the right root-filesystem:
# echo /dev/da0  /  ufs  rw,noatime  1  1 /mnt/etc/fstab

create your rc.conf.local in /mnt/etc to redefine some settings:
# cat EOFRCCONF /mnt/etc/rc.conf.local
#!/bin/sh
tmpmfs=YES
tmpsize=128m
varmfs=YES
varsize=128m
populate_var=YES
hostname=daisy.duck.home
keyrate=fast
EOFRCCONF

# chmod 0755 /mnt/etc/rc.conf.local

set a new root password manually, if you want (default=)
# chroot /mnt /usr/bin/passwd root

well, there are many other things you could do like configuring
hosts, networks, dns, users, add. filesystems, etc... but this
is another stuff!

cu  have fun!

ps: just reply to the list for comments/flames, i'm on it ;-)
pps: thx 2 the installer team for keeping things simple and easy!

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]