Can systemd mount a share for a specific user and show it in the filemanager?

Sheesh, going slightly nuts. I’m still trying to set up a mount unit as a user, but failing hard.

I can manually mount the nfs share with sudo mount -t nfs nas:/mnt/volume1/video /data/nfs/nasvideo.

I can mount the nfs share with sudo systemctl start data-nfs-nasvideo.mount when I place the mount unit in /etc/systemd/system/

But for the life of me, I can’t seem to start the mount unit as a user…

I have a mount unit in ~/.config/systemd/user:

$ cat data-nfs-nasvideo.mount 
[Unit]
Description=Mount video nfs share on nas
After=network-online.target
Wants=network-online.target

[Mount]
What=nas:/mnt/volume1/video
Where=/data/nfs/nasvideo
Type=nfs
Options=_netdev,auto
#TimeoutSec=seconds

[Install]
WantedBy=remote-fs.target
WantedBy=multi-user.target

When I run systemctl --user start data-nfs-nasvideo.mount it gives me this error on the command line plus the following journalctl -xe output:

$ systemctl --user start data-nfs-nasvideo.mount 
Job failed. See "journalctl -xe" for details.

$ journalctl -xe
░░ The process' exit code is 'exited' and its exit status is 32.
jan 31 17:35:25 bliep systemd[1088]: data-nfs-nasvideo.mount: Failed with result 'exit->
░░ Subject: Unit failed
░░ Defined-By: systemd
░░ Support: https://forum.manjaro.org/c/support
░░ 
░░ The unit UNIT has entered the 'failed' state with result 'exit-code'.
jan 31 17:35:25 bliep systemd[1088]: Failed to mount Mount video nfs share on nas.
░░ Subject: A start job for unit UNIT has failed
░░ Defined-By: systemd
░░ Support: https://forum.manjaro.org/c/support
░░ 
░░ A start job for unit UNIT has finished with a failure.
░░ 
░░ The job identifier is 2963 and the job result is failed.
jan 31 17:46:07 bliep systemd[1088]: Mounting Mount video nfs share on nas...
░░ Subject: A start job for unit UNIT has begun execution
░░ Defined-By: systemd
░░ Support: https://forum.manjaro.org/c/support
░░ 
░░ A start job for unit UNIT has begun execution.
░░ 
░░ The job identifier is 3061.
jan 31 17:46:07 bliep systemd[1088]: data-nfs-nasvideo.mount: Mount process exited, cod>
░░ Subject: Unit process exited
░░ Defined-By: systemd
░░ Support: https://forum.manjaro.org/c/support
░░ 
░░ An n/a= process belonging to unit UNIT has exited.
░░ 
░░ The process' exit code is 'exited' and its exit status is 32.
jan 31 17:46:07 bliep systemd[1088]: data-nfs-nasvideo.mount: Failed with result 'exit->
░░ Subject: Unit failed
░░ Defined-By: systemd
░░ Support: https://forum.manjaro.org/c/support
░░ 
░░ The unit UNIT has entered the 'failed' state with result 'exit-code'.
jan 31 17:46:07 bliep systemd[1088]: Failed to mount Mount video nfs share on nas.
░░ Subject: A start job for unit UNIT has failed
░░ Defined-By: systemd
░░ Support: https://forum.manjaro.org/c/support
░░ 
░░ A start job for unit UNIT has finished with a failure.
░░ 
░░ The job identifier is 3061 and the job result is failed.
jan 31 17:46:07 bliep mount[5227]: mount.nfs: failed to apply fstab options

If I run sudo systemctl --user start data-nfs-nasvideo.mount I get the following error:

$ sudo systemctl --user start data-nfs-nasvideo.mount 
Failed to connect to bus: $DBUS_SESSION_BUS_ADDRESS and $XDG_RUNTIME_DIR not defined

I have been searching the web for any sort of information or tutorials, but came up short. The best I could find for the latter errors that you can’t start user systemd mount/service with sudo. Looking at the error, that sounds plausible. Haven’t been able to turn up anything useful for the former errors though.

So I can’t figure out what is going wrong, there just isn’t enough information in the output for me.

I have tried chowning the various files and directories to either my user of root. I have tried chmoding the various files and directories to 777 and/or making them executable.

I have tried the previous in combination with setting the location to mount the share to a directory in my home directory, in /mnt and in the aforementioned /data directory. All to no avail and with exactly the same errors.

I’m gonna make pizza now for the kids, but if someone knows what to do, I will send a liberal amount of emoji your way :smiley: