Rclone Mount Systemd

Hi all,

I am having issues with my rclone.service. Its in /etc/systemd/system/ and when I run the service I get this message
Dec 07 19:50:37 drake systemd[1]: Starting Rclone VFS Mount... Dec 07 19:50:37 drake rclone[5143]: Serving remote control on http://127.0.0.1:5572/ Dec 07 19:50:37 drake rclone[5143]: mount helper error: fusermount: option allow_other only allowed if 'user_allow_other' is set in /etc/fuse.conf Dec 07 19:50:37 drake rclone[5143]: Fatal error: failed to mount FUSE fs: fusermount: exit status 1 Dec 07 19:50:37 drake systemd[1]: rclone.service: Main process exited, code=exited, status=1/FAILURE Dec 07 19:50:37 drake systemd[1]: rclone.service: Failed with result 'exit-code'. Dec 07 19:50:37 drake systemd[1]: Failed to start Rclone VFS Mount. lines 1-13/13 (END)

My service file is like that

# /etc/systemd/system/rclone.service
[Unit]
Description=Rclone VFS Mount
After=network-online.target

[Service]
User=1000
Group=1000
Type=notify
#ExecStartPre=/bin/sleep 10
ExecStart=/usr/bin/rclone mount \
  --allow-other \
  --buffer-size=64M \
  --config=/home/drake/.config/rclone/rclone.conf \
  --dir-cache-time=168h \
  --drive-chunk-size=64M \
  --drive-skip-gdocs \
  --fast-list \
  --rc \
  --rc-web-gui \
  --syslog \
  --timeout=10m \
  --umask=002 \
  --vfs-read-chunk-size-limit=2048M \
  --vfs-read-chunk-size=64M \
  -v \
  google: /mnt/remote
ExecStop=/bin/fusermount -uz /mnt/remote
Restart=on-abort
RestartSec=5
StartLimitInterval=60s
StartLimitBurst=3

[Install]
WantedBy=default.target

I think its something to do with After=network-online.target

Thank you

I think the error here tells you all you need to know - but just to break it down further you need to:

  • Open the file /etc/fuse.conf in a text editor
  • Change the line that says user_allow_other . I think by default it is commented out and all you need to enable it is remove the comment at the start of the line.
  • Save the file and exit - then run your script again.

This is not really related to rclone, but is a security-setting for FUSE (rather rclone uses on Linux for mounting). As the error explains, FUSE will not allow --allow-other to be until you enable this.
Alternatively it would also work if you removed --allow-other but of course then onlythe user-account that mounted the drive would be able to use it (ie. the root account, which is not practical).