What is the problem you are having with rclone?
I am not able to start rclone mount at boot on a raspberry pi 4
What is your rclone version (output from rclone version
)
rclone v1.45
- os/arch: linux/arm
- go version: go1.11.6
Which OS you are using and how many bits (eg Windows 7, 64 bit)
PRETTY_NAME="Raspbian GNU/Linux 10 (buster)"
NAME="Raspbian GNU/Linux"
VERSION_ID="10"
VERSION="10 (buster)"
VERSION_CODENAME=buster
ID=raspbian
ID_LIKE=debian
Which cloud storage system are you using? (eg Google Drive)
One Drive
The command you were trying to run (eg rclone copy /tmp remote:tmp
)
I configured rclone mount to mount (only write mode) a one drive folder. Using the command:
rclone --vfs-cache-mode writes mount --daemon --allow-non-empty "onedrive":raspberry_ftp ~/ftp
the folder is perfectly mounted and it works as expected. What I need, is to mount the folder at startup. So, I created a service in /etc/systemd/rclone.service:
[Unit]
Description=One Drive (rclone)
AssertPathIsDirectory=/home/my/ftp
After=network-online.target
[Service]
Type=simple
ExecStart=/usr/bin/rclone mount \
--config=/home/my/.config/rclone/rclone.conf \
--vfs-cache-mode writes \
--allow-non-empty \
onedrive:raspberry_ftp /home/my/ftp
ExecStop=/bin/fusermount -u /home/my/ftp
Restart=always
RestartSec=10
[Install]
WantedBy=default.target
Running the command: systemctl start rclone results in:
==== AUTHENTICATING FOR org.freedesktop.systemd1.manage-units ===
Authentication is required to start 'rclone.service'.
Multiple identities can be used for authentication:
1. ,,, (pi)
2. root
Choose identity to authenticate as (1-2):
password: <-- I insert the password...
polkit-agent-helper-1: pam_authenticate failed: Authentication failure
. Running the same command with sudo, I get:
Failed to start rclone.service: Unit rclone.service not found.
The rclone config contents with secrets removed.
/.config/rclone $ cat rclone.conf
[onedrive]
type = onedrive
token = ...
drive_id = 7c4d17511cae5ec2
drive_type = personal