[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

RFC: pimp my live-helpers



chymian wrote:
> hi list,

Hi,

> I want to open a discussion on how to pimp the great live-helper scripts.

always very welcome.

> as startpoint I have attached a patch against1.0~a41+20080325.095215 which 
> does the following:
> 
> 1. while doing updates for the cache, instead of deleting a cache & copying it 
> complete over, it checks whether rsync is installed and does an 
> rsync --delete -a source/ target/

disadvantage: is slower than hardlinking

i don't think it makes sense to use rsync here, hardlinking is just
simpler, see
http://lists.alioth.debian.org/pipermail/debian-live-devel/2008-March/003389.html

> 2. while we using aufs only within debianLive, here aufs is used to mount the 
> chroot/chroot construction instead of doubling all to chroot.tmp and move it 
> to chroot/chroot.

we discussed this already back in summer 2007 extensively on irc. i'm
not a fan of using aufs during the build process. apart from the fact,
that it is quite a heavy burden to have on the build system (you need to
have kernel and aufs in sync which basically limits capable
build-systems to testing), it's also an additional error source. some
packages are known to behave different when they are used in connection
with aufs (or unionfs), for example both the sun-java and mono
toolchains (i'm aware that those two are not used in the generation of
the rootfs, nevertheless, one can't guarantee that it works with those).

the requirement for the chroot building is, that it is 100% clean; means
no tainting from the host system, no adding/altering/removing of
binaries during installation of the packages for rootfs building.

until we have ro-bind mounts kernel support, i think the two methods we
have are good enough:

  * chroot builds - no requirements to the host system, but slow for
    large live systems

  * non-chrooted builds - for a clean system, the host system and the
    live system must be of the same distribution (e.g. stable and
    stable, or testing and testing etc).

with non-chrooted builds, the tools (genisomage, mksquashfs etc) are
directly used from the host system. this is faster than using aufs
(there's nothing to be done at all). if you run live-helper in a chroot
itself just as you build normal debian packages, it's easy to keep the
host system (inside the chroot) clean and in sync (i'm always using this
method to do my testbuilds).

> also attached is a little script, which can be sourced to get some 
> shellfunctions which come in handy, while playing around with the 
> aufs-construct: 
> lh_aufs [-i] [-u]: to mount & umount the aufs construction
> lh_mount: to mount proc, devpts & sysfs: 
> lh_umount: to umount proc, devpts & sysfs: 

such functions should go to /usr/share/live-helper/functions/aufs.sh or
similar, rather than creating own helpers for them.

Regards,
Daniel

-- 
Address:        Daniel Baumann, Burgunderstrasse 3, CH-4562 Biberist
Email:          daniel.baumann at panthera-systems.net
Internet:       http://people.panthera-systems.net/~daniel-baumann/



Reply to: