[systemd-devel] Stacked automount dependencies

Kenneth Porter shiva at sewingwitch.com
Fri Mar 30 00:19:20 UTC 2018


I need to automount a couple cifs shares on a NAS box, with one share 
mounted to a directory within another share:

/srv/share0/share1

I've created the unit files for .mount and .automount for the two shares, 
with mount disabled and automount enabled and started. This seems to work 
fine once the system is booted. But the share1 automount fails to start on 
boot with the error "dependency". The share0 automount is started and works 
when the mount point is later accessed, but not the share1 automount.

I don't know what to add to satisfy the boot-time dependency of 
srv-share0-share1.automount.

>From the boot log, it looks like the system is trying to actually mount 
these shares. But the server they're being mounted from may not be up yet 
when both are powering up together. That's why I'm using an automount.

Mar 26 18:29:14 saruman kernel: CIFS VFS: Error connecting to socket. 
Aborting operation.
Mar 26 18:29:14 saruman kernel: CIFS VFS: cifs_mount failed w/return code = 
-113
Mar 26 18:29:14 saruman mount: Unable to find suitable address.
Mar 26 18:29:14 saruman systemd: srv-share0.mount mount process exited, 
code=exited status=32
Mar 26 18:29:14 saruman systemd: Failed to mount NAS1 share0.
Mar 26 18:29:14 saruman systemd: Dependency failed for Automount NAS1 
share1.
Mar 26 18:29:14 saruman systemd: Job srv-share0-share1.automount/start 
failed with result 'dependency'.



More information about the systemd-devel mailing list