ibmi-brunch-learn

Announcement

Collapse
No announcement yet.

SCP command not working to copy file but SFTP does

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • SCP command not working to copy file but SFTP does

    I am trying to transfer a file from the AS400 to an Azure server using the scp command. Login is done using SSH keys. I am able to login if I use sftp and PUT to transfer the file but not when using scp. It says:
    exec request failed on channel 0
    lost connection
    I was able to use SCP to transfer a file from the same machine to another Azure server.
    I use this command:
    Code:
    scp -v -P 8022 'srclib/file.txt' sftpUser@destination:destlib
    I can see the programming is able to login to the server, it is just the transfer that is not working.
    Could it be a network or port issue?
    Last edited by JustinWithoutAnE; December 15, 2022, 06:58 AM.
Working...
X