Last active
March 3, 2018 00:04
-
-
Save xianx/a4520bbbe7114f2b23eec899470f2cfa to your computer and use it in GitHub Desktop.
RSync
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo rsync -vrazh --progress [email protected]:/backup/ /ebs/containers/percona-tdba-d/backup |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Basic syntax of rsync command | |
rsync options source destination | |
# -v : verbose | |
# -r : copies data recursively (but don’t preserve timestamps and permission while transferring data | |
# -a : archive mode, archive mode allows copying files recursively and it also preserves symbolic links, file permissions, user & group ownerships and timestamps | |
# -z : compress file data | |
# -h : human-readable, output numbers in a human-readable format | |
# Local to Remote Copy/Sync | |
rsync -vrazh --progress /path/to/source_directory/ username@remote_host:/path/to/destination_directory | |
# source_directory/ = will copy/sync content of source_directory to destination_directory | |
# Remote to Local Copy/Sync | |
rsync -vrazh --progress username@remote_host:/path/to/source_directory /path/to/destination_directory |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo rsync -vrazh --progress [email protected]:/var/www/hosted/www.techtunes.com.bd/httpdocs/tTunes/app/wp-content/ /ebs/containers/php-cms/-wjajta | |
sudo rsync -vrazh --progress [email protected]:/var/www/hosted/www.techtunes.com.bd/httpdocs/tTunes/app/tDrive/ /ebs/containers/php-cms/ryy7ip | |
sudo rsync -vrazh --progress [email protected]:/var/www/hosted/www.techtunes.com.bd/httpdocs/tTunes/app/uploads/ /ebs/containers/php-cms/uot3x7 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo tar -cjvf --exclude"cache/*" wp-content-d2c.tar.bz /ebs/containers/php-cms/-wjajta |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment