Hi.
On Wed, 29 May 2019 10:58:01 -0600 Greg Woods wrote:
worldsys:/install /install nfs rw,x-systemd.automount
0 0
Is it impossible to do a system-upgrade from a remote-mounted repo
(which
would defeat much of the purpose of maintaining such a repo), or is there a
way to make the network come up and the automount happen at system-upgrade
reboot time?
Looking at the man of systemd.offline-updates this should be
possible. See for example near the end:
5. It may be desirable to always run an auxiliary unit when booting
into offline-updates mode, which itself does not install updates.
To do this create a .service file with
Wants=system-update-pre.target and Before=system-update-pre.target
and add a symlink to that file under
/usr/lib/systemd/system-update.target.wants .
## Typo there, it's:
## /usr/lib/systemd/system/system-update.target.wants
I suggest in the following to proceed slightly differently (untested):
[1] system-update.target do not define a Wants=system-update-pre.target
only a After=
add a link to ../system-update-pre.target in
/usr/lib/systemd/system/system-update.target.wants/
[2] create /usr/lib/systemd/system/system-update-pre.target.wants/
[3] put links in it for:
NetworkManager.service
NetworkManager-wait-online.service
autofs.service
[4] Override system-update-pre.target for the ordering
create: /usr/lib/systemd/system/system-update-pre.target.d/override.conf
with:
[Unit]
After=NetworkManager.service NetworkManager-wait-online.service autofs.service
In addition you may gain adding the nolock option to the NFS mount:
that will prevent a requirement to rpcbind and rpc.statd
You can also replace autofs by a static mount defined with a systemd
unit install.mount in which you can declare the Before= ordering
PS: I wonder why you said CIFS in the subject :-)
--
francis