Schedule an rclone copy job

Schedule a tested rclone copy with absolute paths, a protected config, durable logs and explicit exit capture, then verify the first unattended run.

Last reviewed

Schedule only an already verified rclone copy command. copy is additive for destination-only paths, but it can still replace a same-named Dosya file with a new version, so isolate the destination and retain logs.

Four-step workflow for verifying a manual copy, using absolute protected paths, creating a non-overlapping schedule, and checking its first run.
Four-step workflow for verifying a manual copy, using absolute protected paths, creating a non-overlapping schedule, and checking its first run. Open full-size screenshot.

Steps

  1. Run the exact command manually with --dry-run, then without it on one harmless file. Verify the destination before introducing a scheduler.
  2. Find absolute paths for the rclone executable, source, config file and log directory. A scheduler can have a different PATH, home and working directory from your terminal.
  3. Put the tested command in a protected script with absolute paths for rclone, source, remote, config and log file.
  4. Prevent overlap with the previous run using the platform’s lock or single-instance facility. Keep the API key in the restricted config rather than the crontab or command history.
  5. Add the POSIX cron entry or Windows Task Scheduler action under the intended service account, with the script’s absolute path and a deliberate working directory.
  6. Trigger the schedule once now. Capture its exit status, read the fresh log, list the Dosya destination and compare one downloaded sample before waiting for the normal interval.

A POSIX script can run /usr/local/bin/rclone copy /srv/export dosya-webdav:All/nightly --config /etc/rclone/dosya.conf --log-file /var/log/rclone/nightly.log --log-level INFO.

A folder- or workspace-limited key reduces the scheduler’s reach but cannot exceed the member’s permissions. Revoking that key stops future runs; it does not delete files already copied. Replacing a same-name file appends version history and uses storage.

Reference for “Schedule an rclone copy job”: Dosya rclone overview page.
Reference for “Schedule an rclone copy job”: Dosya rclone overview page. Open full-size screenshot.

Expected result

The scheduler’s first unattended execution uses the intended config and paths, produces a durable log and verified destination, and records failure whenever the transfer or its verification command fails.

Unknown remote, config file not found and local source errors usually reveal a different service-account environment. Fix that environment instead of copying the secret into a globally readable location.

Was this helpful?

Loading helpfulness results…

Voting saves a necessary ballot cookie for up to 180 days so you can change your answer.

Questions and replies

Ask about the steps in this guide. Questions are reviewed before publication.

Keep account details, credentials and private files out of public questions. Use private support for those.

Loading questions…

    Sign in to your Dosya account to ask a question.

    Check the outcome before you retry

    Use these shared checks when a task needs a second look.