There are several ways to download a website from the server:
/var/www/
).22
./var/www/
).scp -rC /var/www/example.com/* user@example.ftp.tools:~/example.com/
Command Description:
-r
- copying files recursively in the specified directory, that is, all files and subdirectories will be copied.-C
- using compression for copying. Speeds up the copying process by minimizing traffic. If you have problems with the files after copying, then it should not be used./var/www/example.com/
- the directory to be copied. Please note that at the end of the path you must specify /*
to copy files without creating a directory example.com
... All contents of the directory will be copied to the new server example.com
.user@example.ftp.tools:~/example.com/
- you need to specify SSH connection data and the target directory where the data will be copied:user
- SSH user.example.ftp.tools
- server for connecting via SSH.~/example.com/
- the target directory to which the data will be copied. It is important to consider that ~/
indicates the standard location of the user's directory, that is, it is analogous /home/example/
.yes
.rsync -rvz /var/www/example.com/* user@example.ftp.tools:~/example.com/
Command Description:
-r
- copying files recursively in the specified directory, that is, all files and subdirectories will be copied.-v
- detailed output of all actions when copying.-z
- using compression for copying. Speeds up the copying process by minimizing traffic. If you have problems with the files after copying, then it should not be used./var/www/example.com/*
- the directory to be copied. Please note that at the end of the path you must specify /*
to copy files without creating a directory example.com
... All contents of the directory will be copied to the new server example.com
.user@example.ftp.tools:~/example.com/
- you need to specify SSH connection data and the target directory where the data will be copied:user
- SSH user.example.ftp.tools
- server for connecting via SSH.~/example.com/
- the target directory to which the data will be copied. It is important to consider that ~/
indicates the standard location of the user's directory, that is, it is analogous /home/example/
.yes
.
from 2-00 to 7-00