Backing Up with rsync, iCal, and Applescript

19 Jan 2007 in Apple, AppleScripts by Garrick

This morning marks the completion of the first full backup I’ve done in quite a while. But not the last. For the past 3 months, I’ve been working on an automated backup system – so I no longer need to wonder if things are backed up. They are. In at least two places.

A little background:

The backup system is tiered;

  1. Every couple of days, the “client” Macs, the ones that get used everyday, backup to the Mini with
    rsync -aE --exclude='.*' /usr/bin/ssh /[path to source folder (see below)]/ [username]@[url of local server]:/[path to your backup directory]/

    I’ve got these all wrapped up in a single backup.sh file, with a line for:

    ~/Library/Application\ Support
    ~/Library/Mail
    ~/Library/Keychains
    ~/Library/Documents/Projects
    ~/Library/Documents/Palm
    ~/Pictures
    ~/Desktop

  2. Then, the Mini backs up the client folders to StrongSpace.
    rsync -rltvz --exclude='.*' /usr/bin/ssh /[path to client backup folder]/ [username]@[url of online server]:/[path to your online backup directory]/
  3. I’m using SSH Keys (the /usr/bin/ssh in the strings above) to automate the login (see MagpieBrain for instructions on setting this up).
  4. On all the machines, the backup.sh file is wrapped in an Applescript
    do shell script "/Users/garrickvanburen/Documents/Projects/RSYNC/garrick_backup.sh"
  5. The Applescript is called from an alarm in iCal, like this

What’s your backup strategy?

ELSEWHERE:
David Roessli takes a different approach.


Comment | Trackback URL Short Link: http://grv.me/545

Add a Comment


XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

Related Entries




Creative Commons License
About Sitemap XHTML Sitemap XML
Wordpress theme is a heavily hacked version of "Modicus Remix" by Art Culture. Original by Upstart Blogger