From the course: Red Hat Certified System Administrator (EX200) Cert Prep: 2 File Access, Storage, and Security

Unlock the full course today

Join today to access over 23,300 courses taught by industry experts.

Securely transfer files between systems

Securely transfer files between systems

- [Instructor] There are several different ways of transferring files from one host to another, using an encrypted tunnel. The easiest being SCP or secure copy. SCP acts like the local CP command but the arguments are a bit more complex as you'll see. The syntax for SCP is scp options source file destination file. At first glance the syntax looks the same as the CP command. However, the source and destination files may include the host name or IP address. For instance, to copy the local/etc/host file to a remote server, you might type in, scp /etc/hosts the IP address:/tmp. The source file is the local path and the destination file is an IP address and remote path separated by a colon. We can also copy a remote file to a local location by reversing the arguments. Now, the source is the remote host and the destination has a local path. This copies of remote/etc/host file to the local /tmp directory. By default SCP uses a standard SSH port number of 22. If the remote server uses a…

Contents