...
The following table shows some SCP syntax examples
Task | Command |
---|---|
Copy single file to another system | $ scp <local-file> <user>@<remote-host>:<remote-file-path> |
Copy a directory recursively to another system | $ scp -r <local-path> <user>@<remote-host>:<remote-path> |
Copy a single file from another system | $ scp <user>@<remote-host>:<remote-file-path> <local-file> |
Copy a directory recursively from another system | $ scp -r <user>@<remote-host>:<remote-path> <local-path> |
The following example shows how a small directory tree is copied to a user account named charon from another system:
|
Transferring Files with SFTP
...
The following example shows how a directory structure is recursively copied from the guest system (IP address 192.168.2.107 in the example) by another system:
|
Using General Backup and Restore Commands
...
The following example shows how to use fbackup
/frecover
through ssh
to copy files between two HP-UX systems:
On the source system:
|
The following example shows how to use pax through ssh
to copy files between two HP-UX systems or between an HP-UX system and, for example, a Linux system:
On the source system:
|
Take care not to overwrite any files on the target system! Please read the respective man-pages carefully to learn about additional parameters of the commands and their proper use.
...