Sync the source to the destination, changing the destination only.
Rclone sync is set up by default to sync from local source to cloud destination, so the destination becomes a mirror of the source. In my case from unRAID to OneDrive.
Can I do the reverse? Have rclone sync OneDrive to unRAID?
That way I can drop files into OneDrive and also access them on my unRAID later.
where “/data” is the variable for the local source and “$SYNC_DESTINATION:/$SYNC_DESTINATION_SUBPATH” would be the variable for the cloud destination.
2016/12/23 00:16:00 Local file system at /data: Waiting for checks to finish
2016/12/23 00:16:00 Local file system at /data: Waiting for transfers to finish
2016/12/23 00:16:00 Local file system at /data: not deleting files as there were IO errors
2016/12/23 00:16:00 Attempt 3/3 failed with 0 errors and: directory not found
2016/12/23 00:16:00 Failed to sync: directory not found
The env variables and config ought to be right since I can sync from source to remote but now that you mention it, it might be permissions. The Docker might not have permissions to write to the folder I created on my unRAID. I’ll look into that, thanks for the suggestion!
If you run with -v then near the top of the logs you’ll see the parameters rclone got when run - check that those match what you think they should be.
Executing => rclone -v sync : /data
2017/02/01 19:19:00 rclone: Version "v1.35" starting with parameters ["rclone" "-v" "sync" ":" "/data"]
2017/02/01 19:19:00 Local file system at /data: Modify window is 1ns
2017/02/01 19:19:00 Local file system at /data: Waiting for checks to finish
2017/02/01 19:19:00 Local file system at /data: Waiting for transfers to finish
2017/02/01 19:19:00 Local file system at /data: not deleting files as there were IO errors
2017/02/01 19:19:00 Attempt 1/3 failed with 0 errors and: error listing source: Local file system at /config/:: directory not found
2017/02/01 19:19:00 Local file system at /data: Waiting for checks to finish
2017/02/01 19:19:00 Local file system at /data: Waiting for transfers to finish
2017/02/01 19:19:00 Local file system at /data: not deleting files as there were IO errors
2017/02/01 19:19:00 Attempt 2/3 failed with 0 errors and: error listing source: Local file system at /config/:: directory not found
2017/02/01 19:19:00 Local file system at /data: Waiting for checks to finish
2017/02/01 19:19:00 Local file system at /data: Waiting for transfers to finish
2017/02/01 19:19:00 Local file system at /data: not deleting files as there were IO errors
2017/02/01 19:19:00 Attempt 3/3 failed with 0 errors and: error listing source: Local file system at /config/:: directory not found
2017/02/01 19:19:00 Failed to sync: error listing source: Local file system at /config/:: directory not found
Thanks for clarifying, not sure what happened there, if I copied it over the text wrongly or I used the wrong command!
I just tried running this command rclone -v sync remote:/Test/ /data:
[cont-init.d] 10-adduser: exited 0.
[cont-init.d] 40-config: executing...
crontab => * * * * * /app/rclone.sh
chmod: /config/Rclone.sh: No such file or directory
[cont-init.d] 40-config: exited 0.
[cont-init.d] done.
[services.d] starting services
[services.d] done.
Executing => rclone -v sync remote:/Test/ /data
2017/02/02 22:56:00 rclone: Version "v1.35" starting with parameters ["rclone" "-v" "sync" "remote:/Test/" "/data"]
2017/02/02 22:56:01 remote: Saved new token in config file
2017/02/02 22:56:01 Local file system at /data: Modify window is 1s
2017/02/02 22:56:01 One drive root 'Test': Reading ""
2017/02/02 22:56:02 One drive root 'Test': Finished reading ""
2017/02/02 22:56:02 Local file system at /data: Waiting for checks to finish
2017/02/02 22:56:02 Local file system at /data: Waiting for transfers to finish
**2017/02/02 22:56:02 unraid-banner.png: Failed to copy: open /data/unraid-banner.png: read-only file system**
2017/02/02 22:56:02 Local file system at /data: not deleting files as there were IO errors
2017/02/02 22:56:02 Attempt 1/3 failed with 1 errors and: not deleting files as there were IO errors
So it looks like it’s reading the right folder “Test” on OneDrive, it sees the file unraid-banner.png. And subsequently runs into the read-only error.
I assume this means rclone or the docker it’s running as, doesn’t have write permissions to the local folder?
I then tried running rclone -v sync remote:/Test/ data and this actually kinda worked:
Executing => rclone -v sync remote:/Test/ data
2017/02/02 23:35:00 rclone: Version "v1.35" starting with parameters ["rclone" "-v" "sync" "remote:/Test/" "data"]
2017/02/02 23:35:01 Local file system at /config/data: Modify window is 1s
2017/02/02 23:35:01 One drive root 'Test': Reading ""
2017/02/02 23:35:01 One drive root 'Test': Finished reading ""
2017/02/02 23:35:01 Local file system at /config/data: Waiting for checks to finish
2017/02/02 23:35:01 Local file system at /config/data: Waiting for transfers to finish
2017/02/02 23:35:02 unraid-banner.png: Copied (new)
2017/02/02 23:35:02 Go routines at exit 7
2017/02/02 23:35:02 Waiting for deletions to finish
2017/02/02 23:35:02
Transferred: 87.364 kBytes (77.966 kBytes/s)
Errors: 0
Checks: 0
Transferred: 1
So some success! Except Rclone creates the folder “data” in Rclone’s config folder and the “unraid-banner.png” is copied, when I want it to go into a different folder I specified in the docker setup.