Gentoo Archives: gentoo-dev

From: Marc Schiffbauer <mschiff@g.o>
To: gentoo-dev@l.g.o
Subject: Re: [gentoo-dev] /usr vs. initramfs redux
Date: Fri, 05 Aug 2011 10:17:41
Message-Id: 20110805101651.GA18949@lisa.schiffbauer.lan
In Reply to: [gentoo-dev] /usr vs. initramfs redux by "Robin H. Johnson"
1 * Robin H. Johnson schrieb am 05.08.11 um 02:46 Uhr:
2 [...]
3 > That leaves the only reasonable solution as #2. In terms of minimal
4 > impact, I propose that we offer users with a static system an absolutely
5 > minimal initramfs, that _just_ mounts the required directories. No
6 > modules, no LVM, no MD, no crypto etc - if you want that functionality,
7 > go and use genkernel or dracut. If your fstab contains a line like:
8 > /dev/sdXN /usr ...
9 > Then this initramfs is for you.
10 >
11 > The minimal initramfs would do the following.
12 >
13 > 1. Mount devtmpfs/sysfs/procfs as needed to access devices.
14 > 2. Mount real_root to /newroot
15 > 3. Read /newroot/etc/initramfs.mount and /newroot/etc/fstab
16 > 4.1. If /newroot/etc/initramfs.mount does not exist
17 > Assume it contains only: /usr /var
18 > 5. Mount the combined items from said files
19 > 6. pivot_root.
20 >
21
22 That sounds like a good compromise to me!
23
24 Another thing to consider:
25
26 /etc/init.d/localmount should check whats already mounted and leave
27 that out. But it will act as fallback if the minimal initramfs fails
28 to mount /usr or /var for any reason.
29
30 That way anybody migrating to that "minitramfs" will not risc an
31 unbootable system.
32
33 -Marc
34 --
35 8AAC 5F46 83B4 DB70 8317 3723 296C 6CCA 35A6 4134

Replies

Subject Author
Re: [gentoo-dev] /usr vs. initramfs redux Rich Freeman <rich0@g.o>