1 |
On Tue, Aug 04, 2015 at 02:05:12PM -0400, Ian Stakenvicius wrote: |
2 |
> 1 - if localmount fails, the you end up with everything that currently |
3 |
> 'need's localmount failing -- this means if you have a headless server |
4 |
> someplace that reboots, you may not end up with an sshd to connect |
5 |
> into it just to fix some random localmount failure that might not be |
6 |
> needed for the core system. So, no, I would not like to see |
7 |
> localmount failing unless all other services are adjusted to no longer |
8 |
> need localmount to succeed.[**] |
9 |
|
10 |
This sounds like more an issue with which file systems are critical for |
11 |
mounting, and a good argument for getting rid of localmount. |
12 |
|
13 |
If we don't care whether localmount succeeds or not, the need dependency |
14 |
is the wrong one to use. |
15 |
|
16 |
Maybe we do think certain file systems must be mounted to boot |
17 |
successfully, and if we do, those should have need dependencies and |
18 |
cause failure if they are unable to be mounted, but the others should |
19 |
not. |
20 |
|
21 |
This is a good reason in itself to move away from localmount and |
22 |
netmount. |
23 |
|
24 |
|
25 |
> |
26 |
> Other implementation related questions: |
27 |
> |
28 |
> 2 - dependencies in other services: right now we have things that |
29 |
> need localmount. These will need to be mapped, iirc the prototype |
30 |
> fork maps them to mount.usr and mount.var instead of 'localmount'. So |
31 |
> what happens in the case that everything is on a single filesystem -- |
32 |
> that is, there is no separate mount.usr / mount.var? Dependencies |
33 |
> break in that case, no? Or will a parent mount point 'provide' the |
34 |
> subdirectory tree to satisfy these mounts? Or will there be a totally |
35 |
> different means of mapping filesystem parts a service needs with the |
36 |
> mount points that need to be mounted first? How specific will the |
37 |
> needs of a service need to be in terms of its mount dependencies in |
38 |
> order to safely start, if for instance there is no more assurance that |
39 |
> 'localmount' has started or has successfully finished? |
40 |
|
41 |
My thought on this is that if you have a mount.foobar service and its |
42 |
mountpoint is not listed in fstab, the service would output a message |
43 |
and return success. This should cover the case of a file system being |
44 |
needed but not being a real file system. |
45 |
|
46 |
From the user's side, you could, if everything was on a single file |
47 |
system, just use rc_need in /etc/conf.d/* to remove mount.usr and |
48 |
mount.var from everything. |
49 |
|
50 |
> 3 - dynamic creation of services -- as of right now, openrc needs all |
51 |
> services to exist as files/symlinks in /etc/init.d. Is it a good idea |
52 |
> for a script to be regularly messing with /etc/init.d ? Or will |
53 |
> openrc be changed to have a whole new means of registering |
54 |
> dynamically-created services? |
55 |
|
56 |
To be honest, I am not really a fan of dynamically created services; I |
57 |
would rather not go there. We don't do that for net.*, so I don't think |
58 |
we should for mount.*. |
59 |
|
60 |
> 4 - Dealing with dynamic creation of services at bootup -- openrc |
61 |
> currently generates/refreshes the cache on shutdown or during config |
62 |
> changes so that it doesn't have to do it on startup, thus speeding up |
63 |
> startup. Since /etc/fstab could have changed between shutdown and |
64 |
> startup (and likely not with a chroot involved -- say, after moving |
65 |
> partitions around in a livecd env) then fstab won't match the services |
66 |
> (nor the cache) anymore. At best this would likely mean cache |
67 |
> regeneration, at worst it means the services need to be regenerated |
68 |
> first. And then there's the issue of the strictness of the misaligned |
69 |
> mount.* services in the depend() of other services (#1) upon first |
70 |
> boot of the new /etc/fstab. |
71 |
|
72 |
I'm not exactly sure what the answer would be here, except that you |
73 |
would have to keep the symlinks in sync with fstab. |
74 |
|
75 |
I'm thinking that there will be a couple of defaults (mount.usr and |
76 |
mount.var) that will take care of most situations. |
77 |
|
78 |
Like I said though, any ideas would be good. |
79 |
|
80 |
William |