My system is an immutable system based on definitions that build an image every night (using cleanroom )
I have a number of directories that are automounted by systemd as they are required. These are then symlinked into users home directories e.g. ~/documents/video -> /mnt/video
The client fstab line for that looks like:
<server>:/opt/video/ /mnt/video nfs nfsvers=3,users,noauto,nolock,x-systemd.automount,x-systemd.mount-timeout=10,timeo=14,_netdev 0 0
The problem is that, after login, it takes a good minute or two for these directories to become available and anything that uses them early on in a user session hangs until they become available.
My suspicion is that this is happening due to a race between systemd.automount and tmpfiles being created. The output of "systemctl status systemd-tmpfiles-setup.service" includes messages like:
Sep 06 14:40:48 <hostname> systemd-tmpfiles[520]: Skipping /mnt/video```
Is there a simple way to make sure that the automount/fstab stuff doesn't happen until after the tmpfiles are created? Or the other way round if that's the issue...