[systemd-devel] [RFC] Network files system mounts should not (always) hold up boot.

Tom Gundersen teg at jklm.no
Mon Apr 2 07:35:11 PDT 2012


Sorry for dropping the list...

On Apr 2, 2012 4:04 PM, "Colin Guthrie" <colin at guthr.ie> wrote:
>
> 'Twas brillig, and Tom Gundersen at 02/04/12 14:51 did gyre and gimble:
> >> > In our discussions, I was concerned that remote-fs.target was a
> >> > pre-requisite of systemd-user-sessions.service as on my machine, my
> >> > /mnt/scratch NFS mount delayed the display manager startup when it
has
> >> > absolutely nothing to do with logins.
> >>
> >> Why should remote fs be ordered before user login at all?
> >
> > Never mind this comment, I was being daft. The other question still
holds.
>
> :) Yeah for /home on NFS is the reason which I presume you realised :D

Indeed, and this is what I
am using...

> >> I have been using automount to achieve similar behaviour to what you
> > want. Might that be an option?
>
> Well it's an option, but still not one that is currently handled
gracefully.

I agree, it can and should be improved, though the user experience is not
too bad at the moment.

> If the /home is now an NFS automount (or /home/$USER itself), then the
> network still needs to be available for the automount to work.

Currently, it is up to the admin to select which mounts should block boot.
In other words, to get the feature you describe I would mark the partitions
that are needed for login as regular mounts and the ones that are not
needed as automounts.

However, we can do better, and this is what I do: mark all partitions as
automount and let kdm start while /home is being fscked or mounted over nfs.

> If prefdm starts and lets users login before the network is ready, will
> the automount simply block until the network is available?

Correct, this would have to be improved before the general user would be
happy with home on automount. Currently kdm blocks with a black screen
until home is mounted. In an ideal world, kdm would first of all show fsck
progress from systemd, and second of all make reads from /home asynchronous
(so pictures would appear once home is mounted). Maybe it would also make
sense for kdm to not allow the user to log in until some info (such as
previous session) is available, in which case kdm should block with a
"please wait" message. At any rate, imho gdm/kdm should decide how to act
without systemd having to be involved.

> If so then it's a reasonable workaround IMO, but it may still be
> desirable to get the mounts available first (e.g. to look up faces or
> find users' last login session type in the DM itself etc.)
>
> Otherwise the DM may only be half ready - e.g. hang while reading the
> users' homedir (and waiting for the mount).

See above.

> So maybe the fixed mounts are still desirable.

I agree, at least in the short/medium term. Though I am not sure if we need
an extra target for this, the admin could simply leave the /home partition
as not  automounted.

Just my two cents :-)

Cheers,

Tom
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/systemd-devel/attachments/20120402/5f4fffaa/attachment.htm>


More information about the systemd-devel mailing list