In the Linux system, the file can be transferred to the FPT space through SSH, some important data backup, then how to achieve the transfer of the file? Small series to give you a detailed introduction to Linux using SSH to transfer files to the FTP space method.
Suppose the directory to be backed up is/home/wwwroot/aaa/, and the IP for the remote FTP space is 22.214.171.124
1. Access to the/home/wwwroot/directory
2. Then compress the AAA directory into the tar.gz file package aaa.tar.gz
Tar CFZ aaa.tar.gz AAA
3. Link FTP
Enter the FTP user name, return, enter the FTP password, link successful, you should see the FTP
4. Upload just the aaa.tar.gz
Until the feedback says success.
Note: If you use the FTP command to prompt This command does not exist
CentOS can directly execute the following command, the installation of the FTP service is generally OK:
Yum Install FTP
By the introduction of this article you must have learned how to use SSH to transfer files to FPT space, a total of four steps, it is simple to back up important files.