Rsync – The Free Backup Solution

Before you dive into this article you need to know that you will be using the terminal. The terminal can look really scary but trust me it’s not all that bad.

Rsync is a command line utility that can sync your data to other places on your hard drive, from hard drive to hard drive or from computer to computer! I personally use Rsync to make daily backups of my websites, to make a backup of all my music and to move my MySQL databases from one server to another. Rsync is included with every install of OS X and is available for Unix and Linux.

Let’s make up a story to use as an example! Joe Brown has a PowerMac G5. He stores all of his music in the Music folder in his home folder. It looks something like this – /Users/joebrown/Music/. That’s the path to his music. Joe Brown is an intelligent user and knows that he should backup whatever data is important to him. Joe Brown goes to Small Dog Electronics and picks up an external hard drive. He gets home and plugs it into his computer. Joe Brown renames his new hard drive to ‘Audio’. The path to the new hard drive is /Volumes/Audio/ (you’ll also find Macintosh HD in /Volumes/. All the hard drives and flash keys, and other storage devices are kept in /Volumes/). Joe Brown wants to sync all the music from /Users/joebrown/Music/ onto his new hard drive.

The command Joe Brown uses in his terminal window is:

rsync -avz /Users/joebrown/Music/ /Volumes/Audio/

This command will synchronize files from Joe’s internal hard drive (specifically his music) to his new external hard drive called ‘Audio’.

This is a simple, basic way to use rsync. This example should help you sync from one place on your hard drive to another or an external hard drive.

A similar command:

rsync -avz /Users/joebrown/Music/ /Users/joebrown/Desktop/

will sync your music to your desktop. Although that doesn’t seem practical it’s completely doable!

Rsync can be automated with other command line utilities. For example I set my rsyncs to run in the early morning hours so they don’t disturb my users. You may set your rsync to run in the morning hours too or the late evening, whenever it’s convenient for you. The utility that allows you to schedule this is called a cron. You can have 1 or 2 or 100 crons. Each cron has a command that it will run at a specific time. Crons are a whole other blog post, but here’s a couple links about rsync and crons!

Readers are more then welcome to email me if they need help!

Rsync Home page
Rsync Examples
Wikipedia – Rsync
Wikipedia – Cron
Automating Tasks w/ Crons
Intro to Cron
Cron Help Guide


Similar Posts

  • Using iTunes with Multiple Drives

    There was a time when all my media (TV shows, music, movies) fit on a single 80GB hard drive, but now that broadband…

  • Get Ready for Lion

    With Mac OS X Lion slated for release this month, it’s important to make sure your Mac is ready if you’re planning a…

  • Instantly Backup Your Address Book

    I typically use iSync and .Mac to backup and sync my Address Book across multiple Macs, and on my Treo cell phone. However,…

  • How to Type the Apple Logo

    If you want to type the stylized Apple logo that Apple uses in all it’s advertising, simply hold down the option-shift-k keys all…

  • How to Clean your Computer

    by Matt, matt@smalldog.com (wirtten by Matt, posted by Ed) Customers often ask whether it’s necessary to clean out their computers. One customer believed…

  • Mac Treat #7: Empty Your Trash Super Fast!

    Emptying the trash in OS X can be a pain. It’s simply one of those easy-to-do-but-ever-so-arduous tasks that devour microseconds of life (actually,…