Last active
January 18, 2022 03:02
-
-
Save seahrh/f566876adb5757a487183cd01aa1cef2 to your computer and use it in GitHub Desktop.
prefer rsync to scp. See https://linux.die.net/man/1/rsync
This file contains hidden or 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
# -v, --verbose | |
# -a, --archive want recursion and preserve almost everything | |
# -P same as --partial --progress | |
# -z, --compress compress file data during the transfer | |
rsync -vaPz file.txt user@server:~/user | |
rsync -vaPz dir user@server:~/user | |
rsync -vaPz user@server:~/user/file.txt . | |
rsync -vaPz user@server:~/user/dir . | |
# from local laptop | |
ssh -O exit hostname | |
ssh -A hostname | |
# on hostname, check your agent | |
ssh-add -L | |
# assuming ^ gives results, do the work | |
rsync ... |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment