Rsync

Copy files from local to remote

rsync -ac ~/dir1 username@remote_host:destination_directory

Copy files from remote to local

rsync -ac username@remote_host:/home/username/dir1 place_to_sync_on_local_machine

Archive Mode

  • Archive mode () is known for giving problems with permissions, in such case i usually use these options -rpcv