Gentoo Archives: gentoo-user

From: Alan McKinnon <alan.mckinnon@×××××.com>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] Re: After /usr conflation: why not copy booting software to /sbin rather than initramfs?
Date: Tue, 27 Mar 2012 22:43:22
Message-Id: 20120328003927.10442dff@khamul.example.com
In Reply to: Re: [gentoo-user] Re: After /usr conflation: why not copy booting software to /sbin rather than initramfs? by Alan Mackenzie
1 On Tue, 27 Mar 2012 22:01:28 +0000
2 Alan Mackenzie <acm@×××.de> wrote:
3
4 > Hello, Neil.
5 >
6 > On Tue, Mar 27, 2012 at 10:41:53PM +0100, Neil Bothwick wrote:
7 > > On Tue, 27 Mar 2012 21:24:22 +0000, Alan Mackenzie wrote:
8 >
9 > > > That is precisely what the question was NOT about. The idea was
10 > > > to copy (not move) booting software to /sbin instead of an
11 > > > initramfs - the exact same programs, modulo noise - to have the
12 > > > SW in /sbin necessary to mount /usr.
13 >
14 > > Your package manager only knows about the copy in the original
15 > > location.
16 >
17 > So? The same applies to a copy in the initramfs.
18
19 No it doesn't. The initramfs is a transient file system contained
20 within a single file. To the package manager, it is just a file, one
21 with a rather unique name that portage is highly unlikely to try and
22 overwrite.
23
24 Copying binaries into / means you are copying a large number of files
25 into an area managed by the package manager. Those files have names and
26 locations that are rather likely to be used by ebuilds.
27
28 Do we really have to spell out to you why this is a bad idea?
29
30 > > When you update you'll have multiple versions of the same program or
31 > > library in your path.
32 >
33 > Well, with the manual/script copying which needs doing either
34 > for /sbin or initramfs, that will be several copies of a program, not
35 > several versions.
36
37 Your copies will be used in preference to the originals in /usr. You
38 will have to detect this yourself when this occurs and re-copy them and
39 portage cannot help you.
40
41 Remember the primary difference between / and an initramfs:
42
43 The initramfs is transient and it's contents are not available to
44 confuse the system once early boot is over.
45
46 / is a permanent file system that is always around, and always there to
47 confuse the issue.
48
49 This is not a small trivial issue, it is huge, and a magnificent
50 bug-injection system.
51
52 > I'm still trying to see the reason why an /sbin with the same
53 > contents as a putative initramfs won't work.
54
55 Oh, it will work for booting all right. It's the issues it will cause
56 after booting when it should no longer be there that is the problem.
57
58
59
60
61 --
62 Alan McKinnnon
63 alan.mckinnon@×××××.com

Replies