Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

This is close to other questions, but I'm having trouble narrowing down the 'optimal' solution for my use case, if there is one. AFAIK this is not a dupe because OSX has different options relevant for its particular flavor of hard drive format. This is also a laptop use case, so I'm looking for solutions that are relatively quick, and they probably can't run on a cron (in case I forget to plug the external drive in before bed).

Here's what I'm using:

  • using OSX snow leopard 10.6.7
  • rsync version 3.0.7 protocol version 30
  • backup to laptop hd in external enclosure
  • one partition only

Here's what I want to be able to do:

  • shut down my laptop
  • take the disk out of the external enclosure and put it into my laptop
  • run laptop

So, this is not a true backup system per se -- deleted files remain unrecoverable, just an insurance policy against hd failure. Note that I should not have to reinstall any applications or operating systems.

Here's what I'm doing now:

sudo rsync -aNHAXx --fileflags --protect-decmpfs --force-change --progress / /Volumes/EXTERNAL/ 

I have yet to test this. (So first question, you think this will work?)

My question is, what can I do to improve on what I'm doing in this command line (other than putting it in a script)? What am I not considering?

Thoughts I have:

  • am I really preserving everything I will need
  • what can I exclude? -- spotlight files? caches?

(Inspired by codinghorror What's Your Backup Strategy? post which is now dated.)

share|improve this question
Since someone recently commented, I have been using CarbonCopyCloner. This question is now relevant again, though, as they are no longer free. – John Hinnegan Sep 11 '12 at 1:38
up vote 3 down vote accepted

My rsync script for a periodic disk clone to a disk mounted at /Volumes/Backup1 is:

sudo rsync -xrlptgoEv --progress --delete / /Volumes/Backup1/

(optional) sudo bless -folder /Volumes/Backup1/System/Library/CoreServices

That's a full bootable clone of the drive.

A few points:

You don't necessarily need to install the backup drive into your laptop. I don't see any reason you wouldn't be able to boot directly from the disk while it's in its USB or Firewire enclosure. (Hold Option at boot to select the boot disk)

Some utilities like Carbon Copy Cloner do this just as well and provide a cleaner interface.

share|improve this answer

I never argue with things inspired by jwz's "Backups" post. But:

First, I'd still put it in cron, and if you're worried that you'll forget to plug the drive in, then adjust your upcoming script to check for the existence of the backup volume before running the rsync. Something like:

if [ -d /Volumes/Backup ]; then
    sudo rsync -vaxE --delete --ignore-errors / /Volumes/Backup/
    # email, SMS, or DM a warning that the overnight backup didn't happen

Second, I'm not sure if I'd use --force-change. There's normally no reason to back up data that hasn't changed, and that will slow your backups down considerably.

Third, the best test of whether or not you preserved everything you need would be to drop the backup drive into your internal bay and see if it boots and you have what you need. Odds are, you will. It's just files on a filesystem.

Fourth, I don't think I'd sweat the time to back up Spotlight caches and other things. I doubt they take up that much space, or that many files, compared to your main body of data.

share|improve this answer

If you want to be able to pull the hard drive out of the enclosure and put it into the laptop you're better off using Carbon Copy Cloner. It's built from the ground up to deal with this use case.

share|improve this answer
I would second CCC for a full system backup! It even features a GUI for creating a LaunchD job. – shustak Sep 9 '12 at 20:26

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.