SCP(1)
π SCP(1) π
okay bestie, so this is the manual page for scp, from the General Commands Manual section of your friendly neighborhood Unix system. sit down, grab a boba, we're learning file copying π«Ά
β¨ NAME β¨
scp β secure copy (remote file copy program). literally what it says on the tin, no cap π
πΈ SYNOPSIS πΈ
scp [-12346BCpqrv] [-c cipher] [-F ssh_config] [-i identity_file]
[-l limit] [-o ssh_option] [-P port] [-S program]
[[user@]host1:]file1 ... [[user@]host2:]file2
like. it's giving "give me a file and a destination and I'll handle it" β¨
π¦ DESCRIPTION π¦
scp copies files between hosts on a network. it uses ssh(1) for the actual data transfer, and it uses the same authentication and provides the same security as ssh(1). so if you trust ssh, you already trust scp. slay. π₯
scp will ask for passwords or passphrases if they are needed for authentication β like it's not gonna just break in silently, it'll ask, because it's polite π
File names may contain a user and host specification to indicate that the file is to be copied to/from that host. Local file names can be made explicit using absolute or relative pathnames to avoid scp treating file names containing ':' as host specifiers. (yes bestie, that colon is doing WORK β it's the whole host separator vibe.) Copies between two remote hosts are also permitted. iconique.
The options are as follows:
π OPTIONS π
-1β Forcesscpto use protocol 1.-2β Forcesscpto use protocol 2.-3β Copies between two remote hosts are transferred through the local host. Without this option the data is copied directly between the two remote hosts. Note that this option disables the progress meter (rip the lil progress bar π).-4β Forcesscpto use IPv4 addresses only.-6β Forcesscpto use IPv6 addresses only.-Bβ Selects batch mode, which prevents asking for passwords or passphrases. no interruptions, just vibes.-Cβ Compression enable. Passes the-Cflag tossh(1)to enable compression. smaller packets, bigger energy β¨-ccipher β Selects the cipher to use for encrypting the data transfer. This option is directly passed tossh(1).-Fssh_config β Specifies an alternative per-user configuration file for ssh. This option is directly passed tossh(1).-iidentity_file β Selects the file from which the identity (private key) for public key authentication is read. This option is directly passed tossh(1).-llimit β Limits the used bandwidth, specified in Kbit/s.-ossh_option β Can be used to pass options to ssh in the format used inssh_config(5). This is useful for specifying options for which there is no separatescpcommand-line flag. For full details of the options listed below, and their possible values, seessh_config(5).
so here's the whole list of what you can hand over through -o, and yes we're listing every single one because bestie we do NOT skip π:
AddressFamilyBatchModeBindAddressCanonicalDomainsCanonicalizeFallbackLocalCanonicalizeHostnameCanonicalizeMaxDotsCanonicalizePermittedCNAMEsCertificateFileChallengeResponseAuthenticationCheckHostIPCipherCiphersCompressionCompressionLevelConnectionAttemptsConnectTimeoutControlMasterControlPathControlPersistGlobalKnownHostsFileGSSAPIAuthenticationGSSAPIDelegateCredentialsHashKnownHostsHostHostbasedAuthenticationHostbasedKeyTypesHostKeyAlgorithmsHostKeyAliasHostNameIdentitiesOnlyIdentityAgentIdentityFileIPQoSKbdInteractiveAuthenticationKbdInteractiveDevicesKexAlgorithmsLogLevelMACsNoHostAuthenticationForLocalhostNumberOfPasswordPromptsPasswordAuthenticationPKCS11ProviderPortPreferredAuthenticationsProtocolProxyCommandProxyJumpPubkeyAcceptedKeyTypesPubkeyAuthenticationRekeyLimitRhostsRSAAuthenticationRSAAuthenticationSendEnvServerAliveIntervalServerAliveCountMaxStrictHostKeyCheckingTCPKeepAliveUpdateHostKeysUsePrivilegedPortUserUserKnownHostsFileVerifyHostKeyDNS
-Pport β Specifies the port to connect to on the remote host. Note that this option is written with a capitalP, because-pis already reserved for preserving the times and modes of the file. yes the case matters bestie, do not come for me π€-pβ Preserves modification times, access times, and modes from the original file. keeping the metadata cute and intact π-qβ Quiet mode: disables the progress meter as well as warning and diagnostic messages fromssh(1).-rβ Recursively copy entire directories. Note thatscpfollows symbolic links encountered in the tree traversal.-Sprogram β Name of program to use for the encrypted connection. The program must understandssh(1)options.-vβ Verbose mode. Causesscpandssh(1)to print debugging messages about their progress. This is helpful in debugging connection, authentication, and configuration problems. the "why is it not working" flag fr fr π
π EXIT STATUS π
The scp utility exits 0 on success, and >0 if an error occurs.
so: zero = we ate. anything bigger = something went wrong π
π SEE ALSO π
sftp(1), ssh(1), ssh-add(1), ssh-agent(1), ssh-keygen(1), ssh_config(5), sshd(8)
the whole ssh cinematic universe, honestly. iykyk π
π HISTORY π
scp is based on the rcp program in BSD source code from the Regents of the University of California. a true legacy icon, generational π
π AUTHORS π
- Timo Rinne
<tri@iki.fi> - Tatu Ylonen
<ylo@cs.hut.fi>
thank you for your service kings π«‘π
and that's the page bestie!! this one came from Debian, dated July 16, 2016 β shoutout to the Debian girlies keeping the SCP(1) manual page alive for us all this whole time. mwah, go copy some files safely π¦β¨π
π¦ where this page comes from
- debian bookworm: openssh-client-ssh1 1:7.5p1-14 Β· OpenSSH
- debian trixie: openssh-client-ssh1 1:7.5p1-17 Β· OpenSSH
- ubuntu jammy: openssh-client-ssh1 1:7.5p1-13 Β· OpenSSH
- ubuntu noble: openssh-client-ssh1 1:7.5p1-16 Β· OpenSSH
- ubuntu questing: openssh-client-ssh1 1:7.5p1-17
- ubuntu resolute: openssh-client-ssh1 1:7.5p1-18 Β· OpenSSH
- ubuntu stonking: openssh-client-ssh1 1:7.5p1-18ubuntu2 Β· OpenSSH
- Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms