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

Re: multistrap rootfs with initramfs

+++ Neil Williams [2009-11-02 10:43 +0000]:
> On Mon, 02 Nov 2009 20:44:23 +1100
> "Brendan Simon (eTRIX)" <brendan.simon@etrix.com.au> wrote:
> > My multistrap rootfs was 'raw'.  i.e. no extra files added.
> > So added the /etc/fstab file (copied from vendor SKD rootfs).
> > Now dpkg --configure -a does not segfault :)
> Weird problems with /dev - seen that before.
> Worth adding a note to the Wiki that at least /proc and /sysfs (and
> probably /dev/pts) need to be mounted before doing anything sensible
> with dpkg.
> > I guess it's a dpkg issue rather than a multistrap issue, but one would
> > have hoped for a more informative error message rather than a segfault.
> True. :-)

I would be good for someone to work out what the actual bug is. A
bugrep pointing out that there is an issue would be a helpful place to
hang such info.

> > Would it be good idea for multistrap to provide some basic default
> > config files.  eg. /etc/fstab, /etc/mtab, ... ??
> But what are sensible defaults? 

> multistrap unpacks the downloaded packages but other stages of
> system configuration are not attempted. Examples include:
>  /etc/inittab
>  /etc/fstab
>  /etc/hosts
>  /etc/securetty
>  /etc/modules
>  /etc/hostname
>  /etc/network/interfaces
>  /etc/init.d
>  /etc/dhcp3 
> Any device-specific device nodes will also need to be created
> using MAKEDEV.

This is a tricky area. It would generally be good to make it easy to
create a bootable rootfs. The packages provide 'sensible defaults' of
some sort but those are never installed if you supply your own. Whilst
emdebian cannot supply sensible default files for everyone it can
supply mechanism for getting them installed in the rootfs easily.

So making it easy to use something like the 'emsandbox'
machines/config stuff with multistrap to get those vital things
populated is probably helpful, to save everyone individually writing a
hacky script like the one I posted, and whatever Brendan has done to
make his stuff work.

The problem with this is that you rapidly get into writing
mini-buildroot if you are not careful...

The other approach is to work on mechanisms for cross-running of the
proper install scripts (which is a much more complete but also _much_
harder problem). Currently only scratchbox and qemu provide working
solutions. Other solutions are very intrusive into dbeian packaging
_and_ can probably never be made to work in all cases (although they'd
work fine in these basic system-config cases). 

I don't know what the right answer is but I do think it is good for
multistrap to include a mechanism for minimal pre-configuration,
perhaps simply done by optionally calling another tool (so as not to
complicate multistrap itself unduly). Keeping rootfs-creation-from
packages and rootfs configuration separated to some degree is good. 

(I have in the mind the '14 different tools for making debian
rootfses' session at last debconf: debootstrap, mutlistrap, fai,
debian-cd, pbuilder, LTSP, d-i,
What is probably really needed is primitives to do the various parts
of this that all these tools could use, but someone has to do a
compleicated anaylsis of the restrictions each of those tools operates
under to work out whether this is actually practical.)

Vagrant started a wiki page about this, but I can;t find it now.

Principal hats:  iEndian - Balloonboard - Toby Churchill - Emdebian

Reply to: