Gentoo Logo
Gentoo Spaceship




Note: Due to technical difficulties, the Archives are currently not up to date. GMANE provides an alternative service for most mailing lists.
c.f. bug 424647
List Archive: gentoo-dev
Navigation:
Lists: gentoo-dev: < Prev By Thread Next > < Prev By Date Next >
Headers:
To: gentoo-dev@g.o
From: Mike Frysinger <vapier@g.o>
Subject: busybox[sep-usr] support for mounting /usr w/out hassle
Date: Sun, 29 Apr 2012 22:00:26 -0400
i've added a new USE=sep-usr flag to busybox.  when enabled, this will install 
a static busybox at /ginit (and have the other busybox paths symlink to that 
so there's no overhead).  this new applet has a hand written set of commands 
to automatically mount /dev /proc /sys /usr and seed /dev, and then execute 
the real init (defaulting to /sbin/init).

to use it, update your kernel command line (in grub.conf or whatever) with:
	init=/ginit
if you want to use a different init from /sbin/init, then just do:
	init=/ginit /some/other/init

this code does not require an initramfs, but if you happen to use one anyways, 
it should be handled automatically.  same goes for any other automatic mount 
aspects of the boot process.

this also address the /usr-merge issue since busybox has all the programs it 
executes built into itself (it's a multicall binary).  this is where the 
openrc early-init scripts failed (they still relied on things in /bin etc...).

this also keeps intact the rescue shell scenario.  the new applet allows you 
to execute other applets.  so booting the kernel with a command line like so:
	init=/ginit bb
will launch our standard static rescue shell.  since it's static, you quite 
literally don't need any other path in the system other than /.

finally, since the recent udev-mount init.d script is completely brain dead and 
refuses to execute unless devtmpfs is enabled, this code will also 
automatically mount+seed /dev (via mdev) if need be.

note: the automatic mounting of /usr applies only to filesystems that (1) the 
kernel can natively mount (i.e. no module autoloading) and (2) do not require 
external mount helpers (i.e. `mount.ntfs3g` or `mount.cifs`).  i don't think 
either of these are a big deal.  if they are, well, use an initramfs :P.

this should address the council's requirement (sep-/usr w/out initramfs) while 
allowing the general craziness to proceed w/out forking projects ourselves.

this is all in busybox-1.20.0 which is now in the tree.  if people want to try 
it out before i unmask it, that'd be great.  seems to work in my qemu setup, 
and on the s390/s390x systems which really don't have a choice when it comes 
to a sep-/usr (due to limitations in the s390 hardware env).
-mike
Attachment:
signature.asc (This is a digitally signed message part.)
Replies:
Re: busybox[sep-usr] support for mounting /usr w/out hassle
-- Walter Dnes
Re: busybox[sep-usr] support for mounting /usr w/out hassle
-- Maxim Kammerer
Re: busybox[sep-usr] support for mounting /usr w/out hassle
-- Ulrich Mueller
Re: busybox[sep-usr] support for mounting /usr w/out hassle
-- William Hubbs
Navigation:
Lists: gentoo-dev: < Prev By Thread Next > < Prev By Date Next >
Previous by thread:
Automated Package Removal and Addition Tracker, for the week ending 2012-04-29 23h59 UTC
Next by thread:
Re: busybox[sep-usr] support for mounting /usr w/out hassle
Previous by date:
Automated Package Removal and Addition Tracker, for the week ending 2012-04-29 23h59 UTC
Next by date:
Re: new virtual/pkgconfig to support lighter alternatives


Updated Jun 29, 2012

Summary: Archive of the gentoo-dev mailing list.

Donate to support our development efforts.

Copyright 2001-2013 Gentoo Foundation, Inc. Questions, Comments? Contact us.