Work in progress (the page -- the script actualy works fine ;-))

I implemented a script that generates a very small root filesystem with the bare minimum, but still is more complete than the asmtools.

The script downloads everything for you, and is made to be "restart friendly" meaning you can hack, add bits etc without having to recompile everything.

It takes about ~15 minutes to build everything from scratch on my quad core.

Question, comments: <buserror@gmail.com>

Executive Summary

$ cd /opt

$ git clone git://bifferboard.git.sourceforge.net/gitroot/bifferboard/bifferboard

$ cd bifferboard/busy

$ ./build_minifs.sh



% ll -h download

total 142M

-rw-r--r-- 1 16M Oct 26 19:40 binutils-2.19.1.tar.bz2

-rw-r--r-- 1 1.9M Oct 8 02:49 busybox-1.15.2.tar.bz2

-rw-r--r-- 1 1.9M Oct 4 12:07 crosstool-ng-1.5.0.tar.bz2

-rw-r--r-- 1 1.6M Nov 12 2008 dropbear-0.52.tar.bz2

-rw-r--r-- 1 57M Oct 26 19:41 gcc-4.3.4.tar.bz2

-rw-r--r-- 1 1.8M Oct 26 19:39 gmp-4.3.1.tar.bz2

-rw-r--r-- 1 938K Jun 27 09:57 jpegsrc.v7.tar.gz

-rw-r--r-- 1 57M Aug 16 22:22 linux-

-rw-r--r-- 1 407K Oct 24 20:51 mjpg-streamer.tar.bz2

-rw-r--r-- 1 1.1M Feb 25 2009 mpfr-2.4.1.tar.bz2

-rw-r--r-- 1 2.2M Mar 2 2009 uClibc-

-rw-r--r-- 1 485K Jul 18 2005 zlib-1.2.3.tar.gz

If you had these packages lying around already, feel free to pre-populate the download directory!


% ll -h build/*.img build/vmli*

-rw-r--r-- 1 michel michel 4.0M Oct 28 08:29 build/minifs-ext.img

-rw-r--r-- 1 michel michel 8.0M Oct 28 08:29 build/minifs-ipcam-ext.img

-rw-r--r-- 1 michel michel 1.3M Oct 28 08:29 build/minifs-ipcam-squashfs.img

-rw-r--r-- 1 michel michel 732K Oct 28 08:29 build/minifs-squashfs.img

-rw-r--r-- 1 michel michel 846K Oct 28 08:29 build/vmlinuz-bare.bin

-rw-r--r-- 1 michel michel 1.5M Oct 28 08:29 build/vmlinuz-initrd.bin

The vmlinuz come in "-bare" variant that can be flashed into the NOR og 1MB I use:

console=uart,io,0x3f8 init=/linuxrc root=/dev/sda1 rootwait

As foor parameters for the system.

The "vmlinuz-initrd.bin" is a kernel that is "glued" to the mini rootfilesytem, it doesn't need anything else to boot a self-sufficient sytem, I can be flashed oh a SD card, or on your bigger NOR if you are lucky.

To flash the others, you can use:

% dd if=build/minifs-ext.img of=/dev/sd<your SD card partition here> bs=128K

If you just flashed the -ext one, you can use resize2fs on the partition to make it "fit" the physical partition.

Whats that IPcam one then ?

Well when the "bare" filesystems are generated, the script also generate a bigger one, with dropbear (ssh) and mjpg-streamer that implements a full blown IP camera on the bifferboard. It's been tested with a Quickcam Pro 9000. To use it, flash the image on your USB stick, flash the -bare kernel on NOR and boot.

This is basicaly an exemple on how to "customize" your own filesystem.

Oppsie #1: You need to change etc/init.d/rcS first line from #!/bin/sh to #!/bin/hush otherwise mjpg-streamer won't start.

To connect to the camera, just point your browser to http://<dynamicaly assigned IP to the bifferboard>/ . You can also "ssh" in, no need for a serial cable. The default root password is "biff".


The script comes with default host ssh keys for dropbear on the ipcam variant; that's not very secure obviously, so you can just delete patches/dropbear*key the script will recreate new ones just for your system.