Impossible to send a file with SCP, msg: subsystem request failed on channel 0

Hello,

I have been trying to send my ssl certificate files to my NAS, in order to use the same DNS.
ex : mynas.mydomain.duckdns.org & myhassio.mydomain.duckdns.org.

So I tried SCP.

My ssh config file is :
Host mynas.mydomain.duckdns.org
IdentityFile /config/.ssh/key
User username
Port 22

I can connect with this config file to my NAS through SSH without any error.
ssh mynas.mydomain.duckdns.org -F /config/.ssh/config

But when I’m trying the scp command : scp -F /config/.ssh/config /config/testfile mynas.mydomain.duckdns.org:confused:

I have this error :
subsystem request failed on channel 0
scp: Connection closed

Home Assistant 2022.8.7
Supervisor 2022.08.6
Operating System 8.5
Frontend 20220802.0 - latest

scp   /SOURCEPATH   <OPTIONALUSER@><TARGETHOST> : /DESTINATIONPATH

( your scp command omits destination path parameters )
( also note that externally mapped dyndns entries will likely fail if both hosts reside within a single homed LAN segment → use the direct local ip instead )

Hello,

I finally used the rsync addon : Hassio-Addons/rsync at main · Poeschl/Hassio-Addons · GitHub.

Thanks for your answer

1 Like

Use the -O option to use the legacy SCP protocol

5 Likes