[systemd-devel] why does nofail imply no After= in /etc/fstab
Andrey Borzenkov
arvidjaar at gmail.com
Thu Jan 16 08:13:18 PST 2014
В Thu, 16 Jan 2014 16:04:34 +0000
Colin Guthrie <gmane at colin.guthr.ie> пишет:
> >
> > Although with faster boot times, a device in fstab not existing is
> > probably increasingly common. What about splitting the scheduling of
> > .mount jobs such that /sysroot happens early, and everything else
> > listed in fstab happens much later, to give the underlying device
> > every opportunity to appear before the attempt?
>
> Primarily because special casing things is evil.
>
> Perhaps it would be better to just use a much smaller timeout for these
> generated units? Perhaps combine that with some kind of automount magic
> and then we've done all we can?
>
If you leave these units waiting (timeout=0) they will be mounted as
soon as device appears. Actually my experience is, that they
may be mounted even if mount unit already timed out, because I
believe mount unit is Wanted by device implicitly (have I said
I hate those undocumented implicit depenencies?) Regarding ordering and
waiting - "nofail" means those devices are not needed for anything
during boot. They are "nice to have" - mount it if you can or leave it.
So this is actually improvement over old situation - devices won't delay
boot but they also won't need to be mounted manually later.
Of course it may conflict with user doing manual mount. I do not dare
to suggest making mount create transient mount unit and forward request
to systemd though (although this is inevitable in the long run).
More information about the systemd-devel
mailing list