Handshake failed: read tcp on NAS

What is the problem you are having with rclone?

rclone setup on Synology NAS using Putty but unable to move or copy files from remote to NAS.

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

rclone v1.69.0-beta.8425.a78bc093d

  • os/version: unknown
  • os/kernel: 4.4.302+ (x86_64)
  • os/type: linux
  • os/arch: amd64
  • go/version: go1.23.4
  • go/linking: static
  • go/tags: none

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

SFTP.

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

rclone copy -vv emer:SHARED /volume1/Downloads/ --config="/volume1/Downloads/rclone.conf"

Please run 'rclone config redacted' and share the full output. If you get command not found, please make sure to update rclone.

[emer]
type = sftp
host = XXX
user = XXX
port = 21
pass = XXX
sha1sum_command = 4

Double check the config for sensitive info before posting publicly

A log from the command that you were trying to run with the -vv flag

2024/12/10 19:54:05 DEBUG : rclone: Version "v1.69.0-beta.8425.a78bc093d" starti ng with parameters ["rclone" "copy" "-vv" "emer:SHARED" "/volume1/Downloads/" "- -config=/volume1/Downloads/rclone.conf"]
2024/12/10 19:54:05 DEBUG : Creating backend with remote "emer:SHARED"
2024/12/10 19:54:05 DEBUG : Using config file from "/volume1/Downloads/rclone.co nf"
2024/12/10 19:54:06 DEBUG : pacer: low level retry 1/10 (error couldn't connect SSH: ssh: handshake failed: read tcp XXX.XXX.XX.XXX:37640->XXX.XXX.XX.XXX:22: re ad: connection reset by peer)
2024/12/10 19:54:06 DEBUG : pacer: Rate limited, increasing sleep to 200ms
2024/12/10 19:54:06 DEBUG : pacer: low level retry 2/10 (error couldn't connect SSH: ssh: handshake failed: read tcp XXX.XXX.XX.XXX:37642->XXX.XXX.XX.XXX:22: re ad: connection reset by peer)
2024/12/10 19:54:06 DEBUG : pacer: Rate limited, increasing sleep to 400ms
2024/12/10 19:54:07 DEBUG : pacer: low level retry 3/10 (error couldn't connect SSH: ssh: handshake failed: read tcp XXX.XXX.XX.XXX:37644->XXX.XXX.XX.XXX: re ad: connection reset by peer)
2024/12/10 19:54:07 DEBUG : pacer: Rate limited, increasing sleep to 800ms
2024/12/10 19:54:07 DEBUG : pacer: low level retry 4/10 (error couldn't connect SSH: ssh: handshake failed: read tcp XXX.XXX.XX.XXX:37646->XXX.XXX.XX.XXX:22: re ad: connection reset by peer)
2024/12/10 19:54:07 DEBUG : pacer: Rate limited, increasing sleep to 1.6s
2024/12/10 19:54:08 DEBUG : pacer: low level retry 5/10 (error couldn't connect SSH: ssh: handshake failed: read tcp XXX.XXX.XX.XXX:37648->XXX.XXX.XX.XXX:22: re ad: connection reset by peer)
2024/12/10 19:54:08 DEBUG : pacer: Rate limited, increasing sleep to 2s
2024/12/10 19:54:10 DEBUG : pacer: low level retry 6/10 (error couldn't connect SSH: ssh: handshake failed: read tcp XXX.XXX.XX.XXX:37650->XXX.XXX.XX.XXX:22: read: connection reset by peer)
2024/12/10 19:54:12 DEBUG : pacer: low level retry 7/10 (error couldn't connect SSH: ssh: handshake failed: read tcp XXX.XXX.XX.XXX:37652-XXX.XXX.XX.XXX.179:22: read: connection reset by peer)
2024/12/10 19:54:14 DEBUG : pacer: low level retry 8/10 (error couldn't connect SSH: ssh: handshake failed: read tcp 1XXX.XXX.XX.XXX:37654->XXX.XXX.XX.XXX:22: read: connection reset by peer)
2024/12/10 19:54:16 DEBUG : pacer: low level retry 9/10 (error couldn't connect SSH: ssh: handshake failed: read tcp XXX.XXX.XX.XXX:37656->XXX.XXX.XX.XXX:22: read: connection reset by peer)
2024/12/10 19:54:18 DEBUG : pacer: low level retry 10/10 (error couldn't connect SSH: ssh: handshake failed: read tcp XXX.XXX.XX.XXX:37658->XXX.XXX.XX.XXX:22: read: connection reset by peer)
2024/12/10 19:54:18 CRITICAL: Failed to create file system for "emer:SHARED": NewFs: couldn't connect SSH: ssh: handshake failed: read tcp XXX.XXX.XX.XXX:37658->XXX.XXX.XX.XXX:22: read: connection reset by peer

hi,

not using rclone, can you ssh into the nas?


usally, ftp is 21, sftp is 22?
but the logs shows port 22 different XXX.XXX.XX.XXX:22 ?
so which is it?


to keep the logs small, try rclone lsd emer: --retries=1 --low-level-retries=1

not sure what that is?


fwiw, best not to use beta, unless there is a specific reason?

I can ssh into the nas with Putty.
It is 22, as per config that I force to be "/volume1/Downloads/rclone.conf"
I pasted another config that is located on root as I used the basic config command here.
Config in "/volume1/Downloads/rclone.conf" is a copy and paste of config that is perfectly working on my WSL windows computer.
sha1sum_command = 4 = I don't know either I got this using rclone config redacted command as specified in the message guidelines,
I use beta because standard version of rclone gave me same result.

i have a bunch of synbox - synology device
this is an working example

>rclone config redacted bnas_sftp_ts:
[bnas_sftp_ts]
type = sftp
host = XXX
user = XXX
key_file = c:\data\c\combined\main\bnas\keys\bnas2.priv
shell_type = unix
md5sum_command = md5sum
sha1sum_command = sha1sum

your remote is missing
shell_type = unix

Thank you so much. Not easy for newbies like me :smiley:
All fixed now !!

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.