Rclone copy over SSH - Temp directory

What is the problem you are having with rclone?

Not a problem, just need some help to figure out the best solution using rclone.

I currently use rclone to move video files using ssh. These files are then imported by radarr, an application that organizes media files.

The issue is that rclone creates an empty file at the destination which has exactly the same name as the one in the source. Since radarr detects that there is a video file it moves it to a different directory while rclone is still copying (moving).

At first glance this doesn't trigger any issues, in fact rclone is still able to continue reading the file (idk how because the file disappears when you do ls -ltra on the directory, maybe it's hardlinked?). The issue arises when rclone ends the copying process, it verifies that the file is not there, and then restarts the copy again. You end up with two copies one is the file moved by radarr and the other one is a duplicate in the downloads directory.

One of the solutions that I thought was instructing rclone to copy in a temp directory and then moving the complete files to the destination, but I cannot find an option in the rclone CLI that lets me do this.

Another solution could be having .partial files like with Google Drive or other remotes. The SCP remote does not use .partial to copy.

Is there a way to make rclone play well with my setup?

Run the command 'rclone version' and share the full output of the command.

rclone v1.56.2

Which cloud storage system are you using? (eg Google Drive)

SSH to server

The command you were trying to run (eg rclone copy /tmp remote:tmp)

rclone move --log-level ${LOG_LEVEL} --delete-empty-src-dirs --stats 120s --buffer-size 256M --drive-chunk-size 256M --use-mmap --timeout 1m --transfers=4 --checkers=8 --bwlimit=${BWLIMIT} ${BACKEND_SERVICE}:/mnt/storage/docker/downloads/complete /destination

hi,

with rclone, might try --inplace

to try anything barely modern you have to update your rclone first. This is ANCIENT version:) 20+ releases behind....

Then have a look at suggested already --inplace functionality.

With the latest rclone version .partial behaviour should be default for local remotes.