Re: [cooking] Some figures for comparing various live boot modes

[ Thread Index | Date Index | More lists.tuxfamily.org/slitaz Archives ]


On 02/01/2011 12:18, Philippe Lelédy wrote:
modularity will be built in ( it is yet here, to a large extend:
see tazlito script).

SliTaz modulary *is* here, at least in cooking, up to 1021 modules are possible !

Proof #1: aufs

grep BRANCH /var/lib/tazpkg/installed/aufs/receipt sed -i 's|CONFIG_AUFS_BRANCH_MAX_127 =.*|CONFIG_AUFS_BRANCH_MAX_127 =|' \ sed -i 's|CONFIG_AUFS_BRANCH_MAX_1023 =.*|CONFIG_AUFS_BRANCH_MAX_1023 = y|' \

Proof #2: tazlito
	
if ! grep -q " keep-loram" /proc/cmdline && cp \${path}rootfs* /mnt;  then

branch=br=/mnt/.rw
for i in \${path}rootfs* ; do
	fs=\${i#*root}
	branch=\$branch:/mnt/.\$fs
	mkdir -p /mnt/.rw/mnt/.\$fs /mnt/.\$fs /mnt/.rw/mnt/.cdrom
	if [ -f /bin/cromfs-driver ]; then
		cromfs-driver \${path}root\$fs /mnt/.\$fs -o ro,dev,suid,allow_other
	else
		insmod /lib/squashfs.ko.gz 2> /dev/null
		mount -o loop,ro -t squashfs \${path}root\$fs /mnt/.\$fs
	fi
done

HOW-TO:

-1- Standardize on loram-smallcdrom
-2- all modules should be put in a *single* directory, on whatever partition you choose.
-3- for building a new module:
a) decide which previous modules it depends on, and which pkg will make up the new module (this is the only *hard* part) b) using aufs, stack all these modules r/o + one top layer r/w (easy, see tazlito as example) c) tazpkg install-list the-list-of-pkg-my-new-module-is-made-of --root my-aufs-stack
   d) mksquashfs my-aufs-branche-rw modules/dir/rootfs-my-new-module
-4- add this in bootloader
      loram=UUID=<uuid-of-module-partition>,modules/dir/

That's all for automatic modules loading at boot-time. Some little scripts are needed for dynamic loading and unloading.

Ph.L.



---
SliTaz GNU/Linux Mailing list - http://www.slitaz.org/


Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/