0% found this document useful (0 votes)
14 views1 page

SCP File Transfer Example

Uploaded by

kamarajk22
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
14 views1 page

SCP File Transfer Example

Uploaded by

kamarajk22
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 1

SCP File transfer:

To copy a file from your Mac to a Linux server using scp, follow these steps:

Open Terminal on your Mac.

Use the scp command in the following format:

bash
Copy code
scp /path/to/local/file username@remote_server:/path/to/remote/directory
/path/to/local/file: The full path to the file on your Mac that you want to copy.
username: Your username on the Linux server.
remote_server: The IP address or hostname of the Linux server.
/path/to/remote/directory: The path on the Linux server where you want the file to
be copied.
Example
bash
Copy code
scp ~/Documents/myfile.txt [email protected]:/home/user/destination_folder
Additional Tips:
If the Linux server uses a different SSH port (e.g., port 2222), specify it using
the -P flag:
bash
Copy code
scp -P 2222 ~/Documents/myfile.txt [email protected]:/home/user/destination_folder
You will be prompted to enter your password for the Linux server unless you're
using SSH keys for authentication.

You might also like