Sunday, October 13, 2019

SCP how to transfer files to a specific port and with username and password

Usually scp is used with a pem file. Below gives info about SCP usage with username and password.

 scp -P 8222 //filetoupload.zip   user@myremotelocation:/home/mylogin/

/home/mylogin is the login on the remote machine

-P options give facility to specify the Port number to upload the file.

Myremotelocation is the remote location that is the hostname of the target machine.

References:
https://linuxize.com/post/how-to-use-scp-command-to-securely-transfer-files/

No comments:

Post a Comment