SFTP gets stuck at specific files

What is the problem you are having with rclone?

rclone with sftp backend gets stuck at one specific file in a directory. If add filter out this file, it gets stuck on another file in different directory.
After a few hours of trying I thought it was an ssh problem, because it would sometimes get stuck on the md5sum command when called from the console. I have resolved the problem by adding -t parameter to the ssh call, but it didn't help for rclone. The problem can also be solved by adding "< NUL" to the end of the command, but this is not possible with rclone.
During all the trials it started getting stuck on a different file, so it doesn't seem like anything is wrong with the particular file.
I also tried to use the base remote for crypt, but then it gets stuck immediately after start (not file gets transferred).
I tried both latest release and beta versions with the same result.
I tried --dump=requests and --dump=responses (so that I would try and replicate manually what rclone is doing), but they did not provide any additional info.

SFTP is my only option for this server, because I don't have a public IP, and I am using cloudflared for ssh acces from outside. I have tried direct access by IP from inside the network, and it still gets stuck, so it's not cloudflared fault.

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

rclone v1.70.3

  • os/version: Microsoft Windows 10 Home 22H2 22H2 (64 bit)
  • os/kernel: 10.0.19045.6093 (x86_64)
  • os/type: windows
  • os/arch: amd64
  • go/version: go1.24.4
  • go/linking: static
  • go/tags: cmount

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

SFTP self-hosted on a Raspberry Pi 5 (official OS).

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

C:\PProg\Dysk\rclone_beta\rclone.exe copy `
  "C:\Users\Kazik\Documents\The Witcher 3" homerpi_crypt:/mnt/hddbackup/kazik/ `
  --config=D:\BackupScript\rclone\rclone.lapasus.homeRPi.config `
  --stats=1m0s `
  -vv `
  2>&1 | % ToString | Tee-Object -FilePath D:\BackupScript\rclone\Last-run.txt

The rclone config contents with secrets removed.

[homerpi]
type = sftp
shell_type = unix
ssh = ssh -i d:\BackupScript\rclone\cert\id_rsa pi@192.168.1.34

[homerpi_crypt]
type = crypt
remote = homerpi:/mnt/hddbackup/kazik
directory_name_encryption = false
password = 

A log from the command with the -vv flag

2025/08/08 12:26:02 NOTICE: Automatically setting -vv as --dump is enabled
2025/08/08 12:26:02 DEBUG : rclone: Version "v1.71.0-beta.8972.8ffde402f" starting with parameters ["C:\\PProg\\Dysk\\rclone_beta\\rclone.exe" "copy" "C:\\Users\\Kazik\\Documents\\The Witcher 3" "homerpi_crypt:/mnt/hddbackup/kazik/" "--config=D:\\BackupScript\\rclone\\rclone.lapasus.homeRPi.config" "--stats=1m0s" "-vv" "--dump=requests"]
2025/08/08 12:26:02 DEBUG : Creating backend with remote "C:\\Users\\Kazik\\Documents\\The Witcher 3"
2025/08/08 12:26:02 DEBUG : Using config file from "D:\\BackupScript\\rclone\\rclone.lapasus.homeRPi.config"
2025/08/08 12:26:02 DEBUG : fs cache: renaming cache item "C:\\Users\\Kazik\\Documents\\The Witcher 3" to be canonical "//?/C:/Users/Kazik/Documents/The Witcher 3"
2025/08/08 12:26:02 DEBUG : Creating backend with remote "homerpi_crypt:/mnt/hddbackup/kazik/"
2025/08/08 12:26:02 DEBUG : Creating backend with remote "homerpi:/mnt/hddbackup/kazik/mnt/hddbackup/kazik"
2025/08/08 12:26:02 DEBUG : sftp://DESKTOP-ES4BJDO\Kazik@:22//mnt/hddbackup/kazik/mnt/hddbackup/kazik: ssh external: creating additional session
2025/08/08 12:26:02 DEBUG : sftp://DESKTOP-ES4BJDO\Kazik@:22//mnt/hddbackup/kazik/mnt/hddbackup/kazik: ssh external: running: ssh -i d:\BackupScript\rclone\cert\id_rsa pi@192.168.1.34 -s sftp
2025/08/08 12:26:02 DEBUG : sftp://DESKTOP-ES4BJDO\Kazik@:22//mnt/hddbackup/kazik/mnt/hddbackup/kazik: Shell type "unix" from config
2025/08/08 12:26:02 DEBUG : sftp://DESKTOP-ES4BJDO\Kazik@:22//mnt/hddbackup/kazik/mnt/hddbackup/kazik: Using root directory "/mnt/hddbackup/kazik/mnt/hddbackup/kazik"
2025/08/08 12:26:02 DEBUG : dx12user.settings.bak: Size and modification time the same (differ by -752.0181ms, within tolerance 1s)
2025/08/08 12:26:02 DEBUG : dx12user.settings: Need to transfer - File not found at Destination
2025/08/08 12:26:02 DEBUG : dx12user.settings.bak: Unchanged skipping
2025/08/08 12:26:02 DEBUG : sftp://DESKTOP-ES4BJDO\Kazik@:22//mnt/hddbackup/kazik/mnt/hddbackup/kazik: Checking default md5 hash commands
2025/08/08 12:26:02 DEBUG : sftp://DESKTOP-ES4BJDO\Kazik@:22//mnt/hddbackup/kazik/mnt/hddbackup/kazik: ssh external: creating additional session
2025/08/08 12:26:02 DEBUG : sftp://DESKTOP-ES4BJDO\Kazik@:22//mnt/hddbackup/kazik/mnt/hddbackup/kazik: ssh external: running: ssh -i d:\BackupScript\rclone\cert\id_rsa pi@192.168.1.34 -s sftp
2025/08/08 12:26:02 INFO  : gamesaves: Set directory modification time (using DirSetModTime)
2025/08/08 12:26:02 DEBUG : Added delayed dir = "gamesaves", newDst=gamesaves
2025/08/08 12:26:02 DEBUG : input.settings: Size and modification time the same (differ by -764.0148ms, within tolerance 1s)
2025/08/08 12:26:02 DEBUG : profile.settings.bak: Size and modification time the same (differ by -655.2486ms, within tolerance 1s)
2025/08/08 12:26:02 DEBUG : profile.settings: Size and modification time the same (differ by -754.0158ms, within tolerance 1s)
2025/08/08 12:26:02 DEBUG : profile.settings.bak: Unchanged skipping
2025/08/08 12:26:02 DEBUG : profile.settings: Unchanged skipping
2025/08/08 12:26:02 DEBUG : user.settings: Size and modification time the same (differ by 0s, within tolerance 1s)
2025/08/08 12:26:02 DEBUG : user.settings: Unchanged skipping
2025/08/08 12:26:02 DEBUG : input.settings: Unchanged skipping
2025/08/08 12:26:02 DEBUG : steam_autocloud.vdf: Size and modification time the same (differ by -156.9865ms, within tolerance 1s)
2025/08/08 12:26:02 DEBUG : steam_autocloud.vdf: Unchanged skipping
2025/08/08 12:26:02 DEBUG : user.settings.bak: Size and modification time the same (differ by -180.649ms, within tolerance 1s)
2025/08/08 12:26:02 DEBUG : user.settings.bak: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/AutoSave_4dcef_7e922800_44d89d2.png: Size and modification time the same (differ by -545.53ms, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/AutoSave_4dcef_7e922800_46740da.sav: Size and modification time the same (differ by -311.6362ms, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/AutoSave_4dcef_7e922800_46740da.png: Size and modification time the same (differ by -301.6388ms, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/AutoSave_4dcef_7e922800_46740da.sav: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/AutoSave_4dcef_7e922800_46740da.png: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/AutoSave_835a6_7e922800_4505153.png: Size and modification time the same (differ by -424.2327ms, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/AutoSave_4dcef_7e922800_44d89d2.png: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/CheckPoint_4dcef_7e922800_46a1b25.sav: Size and modification time the same (differ by -887.1984ms, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/CheckPoint_4dcef_7e922800_46a1b25.png: Size and modification time the same (differ by -877.1995ms, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/CheckPoint_4dcef_7e922800_46a1b25.sav: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/CheckPoint_4dcef_7e922800_46a1b25.png: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/CheckPoint_4dcef_7e922800_4676866.png: Size and modification time the same (differ by -183.1121ms, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/CheckPoint_4dcef_7e922800_46f3f19.sav: Size and modification time the same (differ by -902.224ms, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_11a7d0_7e61e400_49aae12.png: Size and modification time the same (differ by 0s, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/CheckPoint_4dcef_7e922800_46f3f19.png: Size and modification time the same (differ by -893.222ms, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/CheckPoint_4dcef_7e922800_46f3f19.sav: Unchanged skipping
2025/08/08 12:26:03 DEBUG : Encrypted drive 'homerpi_crypt:/mnt/hddbackup/kazik/': Waiting for checks to finish
2025/08/08 12:26:03 DEBUG : gamesaves/CheckPoint_4dcef_7e922800_4676866.sav: Size and modification time the same (differ by -193.1271ms, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/AutoSave_4dcef_7e922800_44d89d2.sav: Size and modification time the same (differ by -554.5295ms, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/CheckPoint_4dcef_7e922800_4676866.sav: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/AutoSave_4dcef_7e922800_44d89d2.sav: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_53db8_7e401800_58973dc.png: Size and modification time the same (differ by 0s, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_53db8_7e401800_58973dc.png: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_6b4a7_7e425000_2c758f4.png: Size and modification time the same (differ by 0s, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_6b4a7_7e425000_2c758f4.png: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_6b4a7_7e425000_2c758f4.sav: Size and modification time the same (differ by 0s, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/AutoSave_835a6_7e922800_4505153.sav: Size and modification time the same (differ by -432.2358ms, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/AutoSave_835a6_7e922800_4505153.png: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/AutoSave_835a6_7e922800_4505153.sav: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_6b4a7_7e425c00_4ecb5dd.png: Size and modification time the same (differ by 0s, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_6b4a7_7e425c00_4ecb5dd.png: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/CheckPoint_4dcef_7e922800_4676866.png: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_6b4a7_7e528000_3b780c7.png: Size and modification time the same (differ by 0s, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_6b4a7_7e425c00_4ecb5dd.sav: Size and modification time the same (differ by 0s, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_6b4a7_7e528000_3b780c7.png: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_6b4a7_7e425c00_4ecb5dd.sav: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_6b4a7_7e605c00_4c9df5c.png: Size and modification time the same (differ by 0s, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/CheckPoint_4dcef_7e922800_46f3f19.png: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_6b4a7_7e605c00_4c9df5c.png: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_11a7d0_7e61e400_49aae12.sav: Size and modification time the same (differ by 0s, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_6b4a7_7e920400_50c95ac.png: Size and modification time the same (differ by -529.7927ms, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_6b4a7_7e920400_50c95ac.png: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_11a7d0_7e61e400_49aae12.sav: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_8559a_7e408400_543d1d2.png: Size and modification time the same (differ by 0s, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_6b4a7_7e920400_50c95ac.sav: Size and modification time the same (differ by -537.797ms, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_8559a_7e408400_543d1d2.png: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_6b4a7_7e920400_50c95ac.sav: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_53db8_7e401800_58973dc.sav: Size and modification time the same (differ by 0s, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_6b4a7_7e425000_2c758f4.sav: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_53db8_7e401800_58973dc.sav: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_11a7d0_7e61e400_49aae12.png: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_86d7e_7e910000_4958f2a.png: Size and modification time the same (differ by -926.024ms, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_6b4a7_7e528000_3b780c7.sav: Size and modification time the same (differ by 0s, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/QuickSave_4dcef_7e922800_4723faf.png: Size and modification time the same (differ by -33.5031ms, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_6b4a7_7e528000_3b780c7.sav: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_6b4a7_7e605c00_4c9df5c.sav: Size and modification time the same (differ by 0s, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/QuickSave_4dcef_7e922800_4723faf.sav: Size and modification time the same (differ by -42.504ms, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_8559a_7e408400_543d1d2.sav: Size and modification time the same (differ by 0s, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_6b4a7_7e605c00_4c9df5c.sav: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_8559a_7e408400_543d1d2.sav: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/steam_autocloud.vdf: Size and modification time the same (differ by -156.9865ms, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_8559a_7e40a000_4eae69e.png: Size and modification time the same (differ by 0s, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_8559a_7e40a000_4eae69e.sav: Size and modification time the same (differ by 0s, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_8559a_7e40a000_4eae69e.png: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_86d7e_7e910000_4958f2a.sav: Size and modification time the same (differ by -942.0015ms, within tolerance 1s)
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_86d7e_7e910000_4958f2a.sav: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_8559a_7e40a000_4eae69e.sav: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/ManualSave_86d7e_7e910000_4958f2a.png: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/QuickSave_4dcef_7e922800_4723faf.png: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/QuickSave_4dcef_7e922800_4723faf.sav: Unchanged skipping
2025/08/08 12:26:03 DEBUG : gamesaves/steam_autocloud.vdf: Unchanged skipping
2025/08/08 12:26:03 DEBUG : Encrypted drive 'homerpi_crypt:/mnt/hddbackup/kazik/': Waiting for transfers to finish
2025/08/08 12:26:03 DEBUG : sftp://DESKTOP-ES4BJDO\Kazik@:22//mnt/hddbackup/kazik/mnt/hddbackup/kazik: ssh external: creating additional session
2025/08/08 12:26:03 DEBUG : sftp://DESKTOP-ES4BJDO\Kazik@:22//mnt/hddbackup/kazik/mnt/hddbackup/kazik: Running remote command: md5sum
2025/08/08 12:26:03 DEBUG : sftp://DESKTOP-ES4BJDO\Kazik@:22//mnt/hddbackup/kazik/mnt/hddbackup/kazik: ssh external: running: ssh -i d:\BackupScript\rclone\cert\id_rsa pi@192.168.1.34 md5sum
2025/08/08 12:27:02 INFO  :
Transferred:              0 B / 5.528 KiB, 0%, 0 B/s, ETA -
Checks:                42 / 42, 100%, Listed 87
Transferred:            0 / 1, 0%
Elapsed time:        59.9s
Transferring:
 *                             dx12user.settings:  0% /5.528Ki, 0/s, -
System.Management.Automation.RemoteException
2025/08/08 12:27:03 DEBUG : sftp://DESKTOP-ES4BJDO\Kazik@:22//mnt/hddbackup/kazik/mnt/hddbackup/kazik: Not closing 1 unused connections as 1 sessions active
2025/08/08 12:28:02 INFO  :
Transferred:              0 B / 5.528 KiB, 0%, 0 B/s, ETA -
Checks:                42 / 42, 100%, Listed 87
Transferred:            0 / 1, 0%
Elapsed time:      1m59.9s
Transferring:
 *                             dx12user.settings:  0% /5.528Ki, 0/s, -
System.Management.Automation.RemoteException
2025/08/08 12:28:03 DEBUG : sftp://DESKTOP-ES4BJDO\Kazik@:22//mnt/hddbackup/kazik/mnt/hddbackup/kazik: Not closing 1 unused connections as 1 sessions active

Looks like my problem is caused by the md5sum program. If I set disable_hashcheck=true, it works fine. So I have selected alternate checksum commands:
md5sum_command = busybox md5sum
sha1sum_command = busybox sha1sum
and this fixed it.

Interestingly, specifying md5sum_command alone didn't work, rclone would get stuck at sha1sum command then.

1 Like

Hm... I was expecting some more debug output after that log line, from here:

If you run ssh -i d:\BackupScript\rclone\cert\id_rsa pi@192.168.1.34 md5sum, does that work and returns the empty input hash value d41d8cd98f00b204e9800998ecf8427e?

No, it hangs and does not return until I press Ctrl+C.
If I run it directly on the server, it will wait for the input and return the hash after I press Ctrl+D.
The busybox one behaves exactly the same though, so it's strange they work differently for rclone.

Replacing md5sum and sha1sum did not fix this 100%, as it turned out. The problem still appears sometimes, but is less frequent, and rclone doesn't get stuck on the same file every time. Thus if it get's stuck I can make it work by just restarting. I think it's a problem that calls for a proper solution though.

Ah yes, I forgot, but pretty sure that is how it works.

Strange. Are you able to narrow it down somehow? A simpler reproducible case would be ideal. Unfortunately I'm away from computer, so not easy for me to dig into it atm.

Damn, I was hoping there would be an easy solution if rclone misinterpreted md5sum’s output :smiley:

I will try to do that, but I don’t have much hope to find anything. Perhaps I will be able to create a directory of test files, one of which will be always failing. But it will probably only fail on my server (Murphy as usual).

I would gladly try a test build if you were able to add some debug info in order to get more information on what is really happening.

It may be related to a general ssh issue I recently discovered. It seems that ssh md5sum command can get stuck randomly. For me it gets stuck after 4-5 tries if I repeat it rapidly. It does not even have to be md5sum, it gets stuck on any command that is called on the same line as ssh. I have tried many suggested solutions to it (wrapping md5sum in a script, adding -T or -tt parameter to ssh), but none worked except one: if I add “< NUL” suffix after the file name, it never gets stuck. In case this is related to my problem somehow, could you try making a test build that will add “< NUL” as the end of every ssh command? This only works in a single command run with ssh, not when an ssh session is opened and then multiple commands are called, so maybe it’s not relevant, depending on how rclone manages ssh sessions.

Also, maybe it’s relevant, maybe not, sometimes when rclone gets stuck there is a line output in addition to the progress block: “Server Side Moves: 1 @ 1.381 KiB”, and the values never change. I hasn’t been able to catch it with -vv, so I can’t post the full debug unfortunately.

I think I found the minimal set of circumstances to make the problem appear. There are actually two separate problems.

  1. If md5sum_command and sha1sum_command are not set, rclone will get stuck even before sending anything, on checking whether the md5sum is working:
2025/08/15 17:54:15 DEBUG : sftp://DESKTOP-ES4BJDO\Kazik@:22//mnt/hddbackup/test: Checking default md5 hash commands
2025/08/15 17:54:15 DEBUG : sftp://DESKTOP-ES4BJDO\Kazik@:22//mnt/hddbackup/test: ssh external: creating additional session
2025/08/15 17:54:15 DEBUG : sftp://DESKTOP-ES4BJDO\Kazik@:22//mnt/hddbackup/test: Running remote command: md5sum
2025/08/15 17:54:15 DEBUG : sftp://DESKTOP-ES4BJDO\Kazik@:22//mnt/hddbackup/test: ssh external: running: ssh -i d:\BackupScript\rclone\cert\id_rsa pi@192.168.1.34 md5sum
2025/08/15 17:54:16 INFO  :Transferred:              0 B / 0 B, -, 0 B/s, ETA -Elapsed time:         0.0sSystem.Management.Automation.RemoteException
2025/08/15 17:54:17 INFO  :Transferred:              0 B / 0 B, -, 0 B/s, ETA -Elapsed time:         1.0sSystem.Management.Automation.RemoteException
2025/08/15 17:54:18 INFO  :Transferred:              0 B / 0 B, -, 0 B/s, ETA -Elapsed time:         1.9sSystem.Management.Automation.RemoteException

I’m guessing this is because rclone expects md5sum to and and return something, but md5sum called without any parameters starts waiting for the user input, and does not return.

This problem can be easily worked around by setting md5sum_command and sha1sum_command parameters in the config file. Even setting them to their default values md5sum and sha1sum will work, because rclone will then skip checking the commands.

  1. Rclone gets stuck randomly even when md5sum and sha1sum are set. I have narrowed the case to a directory of 4 files synced with my remote server over sftp and almost no additional configuration at least once for every 20-30 runs. This however doesn’t seem to be rclone’s fault, but rather cloudflared’s, because I couldn’t make it stuck when connecting to the server over local network. It does get stuck only if I connect through cloudflared. What’s interesting though, is that rclone does not seem to respect timeouts for sftp connection. It’s understandable that if cloudflared has got a problem and the connection randomly stalls during file transfer, rclone will stall too. But I would expect rclone to detect that no data is being transferred and time the connection out. I can do that in my wrapper by killing rclone if files, checks or data doesn’t change within a specific time, but that seems like a bodge.