Gentoo Archives: gentoo-dev

From: William Hubbs <williamh@g.o>
To: gentoo development <gentoo-dev@l.g.o>
Subject: [gentoo-dev] rfc: improve file system mounting and unmounting in OpenRC
Date: Mon, 27 Jul 2015 22:26:24
Message-Id: 20150727222610.GA3908@linux1.gaikai.biz
1 All,
2
3 I have been looking over this bug for some time attempting to find a
4 good solution [1].
5
6 The original proposal is to add a "want" dependency which would work
7 like "need" but would not fail if the services wanted did not start [2].
8
9 I agree that the "want" dependency is a valid feature request. However, I
10 believe there is a better way to handle the issue in the original bug.
11 Basically, I want to follow the suggestion in this bug instead [3].
12
13 My concern about the original proposal is that it will make netmount try
14 to start all daemons that handle file systems, whether or not they are
15 actually necessary.
16
17 The proposal in [3], on the other hand, is to create a mount script that
18 works like netifrc. It would mount a single file system, which would be
19 determined by the link it was called from, much like how netifrc
20 determines which interface to work on.
21
22 Some of the advantages of this approach are listed in the bug. Here are
23 a few more I can think of.
24
25 - it will eliminate some of our incompatibilities with busybox [4] [5].
26
27 - It will give us honest reports of success or failure with regard to
28 mounting file systems (netmount and localmount can't do that).
29
30 - Currently, we have to skip over certain file systems that we can't
31 unmount during shutdown. With the new approach, if the mount script
32 mounts a file system during boot, it will be able to unmount the same
33 filesystem during shutdown, so that will eliminate more complexity in
34 our mount/unmount handling.
35
36 The one down side of the new approach is the migration away from
37 netmount and localmount. I I will need to keep them as wrappers
38 for a release or two so we can fix all of our other services that
39 have dependencies on them.
40
41 I'll also work on making the transition as smooth as possible for our
42 users. I believe I'll be able to set up the initial symlinks for the
43 multiplexed mount script based on fstab contents automatically, but I'm
44 not sure about how much more automation I'll be able to do. I will
45 automate more as I come across ways to do so, and I am open to
46 suggestions for how to do so.
47
48 Let me know what you think.
49
50 William
51
52 [1] https://bugs.gentoo.org/show_bug.cgi?id=537996
53 [2] https://bugs.gentoo.org/show_bug.cgi?id=406021
54 [3] https://bugs.gentoo.org/show_bug.cgi?id=426944
55 [4] https://bugs.gentoo.org/show_bug.cgi?id=468600
56 [5] https://bugs.gentoo.org/show_bug.cgi?id=468604

Attachments

File name MIME type
signature.asc application/pgp-signature

Replies