- Community aggregator
- Country: United States
Using SCP on a Custom Port (and Avoiding the -p vs -P Mix-Up)
If SSH listens on a nonstandard port, SCP needs to connect to that same port. The easy-to-miss detail is capitalization: use uppercase -P with scp , not lowercase -p . SCP uses the SSH port SCP doesn't have a separate network port. It connects through SSH, which uses TCP port 22 by default. If a…