First off, relax, this isnt all that
hard.
It may be new to you but all it take is a little reading and you will
be confident with FreeBSD
It is certainly worth the effort because in my opinion, FreeBSD is far
superior to Linux in many ways
Netcraft
reports the top 50 server uptimes are dominated by FreeBSD and BSD
based boxes so something has to be right
"Take it a step at a time, and use your mind, and you can do anything
that you want to do" (From
Nick Jr's
Blues Clues)
Also, this step by step uses the generic thewall sources with
consideration of running a DHCP client, a NFS client and telnet
*****If you plan on building your own EZ-PicoSETI-2, You can get the
required confiiguration files here
1. Install FreeBSD 4.5
(The FreeBSD handbook
is excellent for newbies)
I like to choose a miminal install, then CVSup the source and ports
tree over the internet
You could also install any other package configuration the source and
ports tree from CD if you wish tree
2. Use CVSup to
update your sources and ports tree
Here is a CVSup page that should
help
3. Optionally install some applications
Here's some handy application I use for file management. editing and
browsing
Filerunner Great file management tool
Glimmer Amazing GUI editor
GFTP Excellent FTP/SFTP
client
These are all FreeBSD ports
4. Download and the sources for theWall (I
used thewall.pc.dhcp.x.tgz)
5. Decompress theWall sources into
/usr/src/release/picobsd
#cp thewall-source.tar.gz /usr/src/release/picobsd
cd /usr/src/release/picobsd
tar zxvf thewall-source.tar.gz
6. Apply 2 thewall patches to
the sources
Dont be scared, this is fun
Chuck has 2 patches that should be applied to the FreeBSD sources
These patches are in thewall's patches directory
(/whatever/thewall.pc.dhcp.x/patches)
The patches are called boot2.c.patch and userconfig.c.patch
Here is the way I applied the patches
Copy boot2.c.patch to /usr/src/sys/boot/i386/boot2
Copy userconfig.c.patch to /usr/src/sys/i386/i386
As root, CD to these directories and type the following
#patch boot2.c.patch boot2.c
and
#patch userconfig.c.patch
userconfig.c
The userconfig.c patch should go without interaction
The boot2.c patch will probably go like this
Patching file boot2.c using Plan A...
Reversed (or previously applied) patch detected! Assume -R [y]
That's normal and ok, just select y for yes
Way to go, you just patched some FreeBSD source code
7. Edit the crunch.conf file
The crunch.conf file is a very important configuration file
It
is located in /usr/src/release/picobsd/thewall.pc.dhcp.x
It determines what programs are linked together to form a single
crunched binary
Under, Linux this same idea is called busybox
The most important part of the crunch.conf are the progs lines
Here are a few lines for example
progs sh test echo hostname ln
login getty stty
progs inetd telnetd w msg kget
reboot
The progams sh, test, echo ... will all be crunched into a single
executable
This is great for space saving
If you plan to change your PicoBSD floppy distro, you must edit
crunch.conf
If you plan on removing some programs, you may break some dependancies
so do one at a time
(For example if I remember correctly, the DHCP client script needs the
program less)
If your PicoBSD floppy compiles without errors, your crunch.conf is
probably ok
Here is an example of my modified crunch.conf to include DHCP, Telnet
and NFS
progs sh test echo hostname ln
login getty stty
progs inetd telnetd w msg kget
reboot
progs init ifconfig df sps ns vm
cat
progs cp rm mknod chmod chown
mkdir ls syslogd
progs sysctl route pwd_mkdb
dev_mkdb
progs mount mount_nfs umount
minigzip sed
tar tail sleep
progs kill
progs dhclient ee
progs pwd less
progs passwd date
progs ping
progs kldstat kldload
progs ftp rmdir mv dialog
8. Edit the Kernel configuration file
The kernel configuration file is called PICOBSD.
It
is also in /usr/src/release/picobsd/thewall.pc.dhcp.x
It is common practice to have the kernel config file in upper case
The PicoBSD kernel compile depends on this configration file
You could consider remarking out unwanted lines to reduce the final
kernel size
By default, thewall takes care of NIC modules in an excellent way
The ISA modules are enabled by default and at boot time you can tweak
the kernel to enable/configure/disable these modules
The PCI modules are not included in the kernel compile are on the
driver disk
If you look at the PICOBSD file you will normally see all PCI modules
are remarked
You can easily edit the PICOBSD file to tailor is specifically to your
system
We wanted to use NFS so these settings were necessary
options NFS
options
NFS_NOSERVER #Network Filesystem
If you want to crunch
SETI
you must ensure these settings
#marker
def_sz init
MFS_inodes floppy_inodes
#PicoBSD
5120 init
4096
32768
options MD_ROOT_SIZE=5120 # same as def_sz
If you need more info, the
FreeBSD
handbook has some excellent coverage of the kernel configuration file
I have several EZ-PicoSETI distros now and each has their own unique
crunch.conf and PICOBSD kernel config file
Here is a chart outlining the different distro types with links
to the
source files for your reference.
9. Build your distro
cd to your
/usr/src/release/picobsd/thewall.pc.dhcp.x directory
As root type this
./thewall
Whatch it fly
10. Create your floppy
Thewall's (picobsd) script will compile a kernel build the crunched
binary and hopefully prompt you with a disk creation dialog box
Assuming this worked without error, you simply have to pop your floppy
disk in the FreeBSD boxes drive and click ok
If your disk image doesnt copy over ok, don't worry the picobsd.bin
file is still waiting for you
Try formatting your floppy using this
#fdformat /dev/fd0 Formats and verifies a 1.44 MB
floppy
or
#fdformat /dev/fd0.1480 Formats and verifies a 1.48
MB floppy - The largest PicoBSD can create and boot from
After getting a disk to properly format and verify, cd to the
build_dir-thewall.pc.dhcp.x directory
You floppy disk image picobsd.bin is there
Use this to copy the image to your floppy
dd if=picobsd.bin of=/dev/fd0 bs=1024
dd if=picobsd.bin of=/dev/fd0.1480 bs=1024 Use this for 1.48MB
floppy images