Skip to content

Instantly share code, notes, and snippets.

@mvneves
Last active August 29, 2015 14:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mvneves/dc7c622b71181cc8e37b to your computer and use it in GitHub Desktop.
Save mvneves/dc7c622b71181cc8e37b to your computer and use it in GitHub Desktop.
Download an entire Amazon EC2 instance to local host using rsync

Download an entire Amazon EC2 instance to local host using rsync

rsync -av --progress -e 'ssh -i /path/to/user.pem' \
--rsync-path='sudo rsync' --exclude='/dev/' --exclude='/proc/' --exclude='/sys/' \
user@ec2-xx-xx-xx-xx.us-west-2.compute.amazonaws.com:/* /local/path/

Actually, this doesn't download the instance itself, but its file system contents.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment