how to send files thorough ssh
- User
how to send files thorough ssh
- Assistant
To send files through SSH, you can use the
scp(secure copy) command. Here's how you can do it:-
Open a terminal on your local machine.
-
Use the following command syntax to transfer a file from your local machine to a remote server:
scp /path/to/local/file username@remote_server:/path/to/destination/directoryReplace
/path/to/local/filewith the path to the file on your local machine,usernamewith your username on the remote server,remote_serverwith the IP address or hostname of the remote server, and/path/to/destination/directorywith the directory on the remote server where you want to copy the file.-
You will be prompted to enter the password for your username on the remote server. Once you enter the password, the file transfer will begin.
-
To transfer a file from the remote server to your local machine, use the following command syntax:
-