This https://wiki.archlinux.org/index.php/Systemd article mentions
Remote filesystem mounts
If you have NFS mounts listed in /etc/fstab then systemd will attempt to mount them but will typically do so too early (before networking has been configured). To get the timing correct we need to tell systemd explicitly that the mount depends on networking and rpc.statd. To do this, create the following file:
[Unit] Description=<mountpoint> Wants=rpc-statd.service After=network.target rpc-statd.service [Mount] What=<server>:<share> Where=<mountpoint> Type=nfs
This Gentoo Wiki page also has some work-in-progress comments:
In the above:
- mount-unit-name is the full path to the mountpoint in an escaped format. For example, a mount unit for /usr/local must be named usr-local.mount.
- mountpoint is the local mountpoint
- server:share specifies the remote filesystem in the same manner as for /etc/fstab
See systemd.unit(5) and systemd.mount(5) for further details.
A similar approach will probably be required for other remote filesystem types such as nfs4 and cifs.
Alternatively, you can mark these entries in /etc/fstab with the x-systemd.automount and x-systemd.device-timeout=# options (see systemd.mount(5)). Make sure that if you also include defaults as a mount option, that you override the implicit auto with noauto. This will cause the device to be mounted on first access, similar to Autofs
systemd - Gentoo Linux Wiki