Skip to content

Instantly share code, notes, and snippets.

@Fartomy
Last active February 19, 2023 20:25
Show Gist options
  • Save Fartomy/7d9b500143e0845da5540b9e4eb0c4d9 to your computer and use it in GitHub Desktop.
Save Fartomy/7d9b500143e0845da5540b9e4eb0c4d9 to your computer and use it in GitHub Desktop.
Function of scp Command

🌐 Function of SCP Command

📕 SCP Command Meaning

SCP (secure copy) is a command-line utility that allows you to securely copy files and directories between two locations. For example, it can be used while connected to a device via ssh.

Usage

scp [OPTION] [user@]SRC_HOST:]file1 [user@]DEST_HOST:]file2
  • OPTION - scp options such as cipher, ssh configuration, ssh port, limit, recursive copy …etc.
  • [user@]SRC_HOST:]file1 - Source file
  • [user@]DEST_HOST:]file2 - Destination file

For Example

scp user1@host1.com:/files/file.txt user2@host2.com:/files
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment