Daily Archives:October 31st, 2008

Limiting the size of your Time Machine

If you use Apple’s wonderful Time Machine backup system, the best thing to do is to give it a hard disk of its own, or a partition of its own, because it tends to grow over time to fill the space available, and trimming it later is not easy.

I’ve got about 3TB of space on my Drobo, and I don’t want it all used for TM, but partitioning is a bit of a nuisance. Fortunately, there’s a free tool you can download from Drobo called Time Tamer, which you can use for any large disk, and which will limit your TM backup space to twice the size of your internal hard drive.

For those of you who want more control and who are interested in what’s happening under the bonnet, though, you can do this yourself. It involves creating a sparse disk image file with the right characteristics and name. TM will then use that instead of creating its own folder structure, and you can limit the size to which the sparse image will grow.

Here’s my command line:

hdiutil create -size 400g -fs HFS+J -volname "TM-backup-of-tafelberg" /Volumes/Drobo/tafelberg_0016cb9125cf.sparsebundle

  • 400g is the max amount of space I want it to take – the max size of the sparse image.
  • tafelberg is the name of my machine
  • Drobo is the name of the hard disk I’m using
  • 0016cb9125cf is the MAC address of my machine’s ethernet port

This creates a sparse image on the disk called, in my case, tafelberg_0016cb9125cf.sparsebundle.
If you switch off Time Machine, move, rename or delete any Backups.backupdb folder that TM may have created there, run an appropriately modified version of this command, and then switch TM back on and select the original disk as the one to use, TM should notice this image and use it to store the backups.

I guess you’ll know if it worked if TM doesn’t create Backups.backupdb again at the top level of the disk!

Followup: Mmm. I found that, when I used this method, and then went into Time Machine, I didn’t get the pretty windows disappearing into the past – it just showed Today. If I mounted the image as a drive, however, the backups seemed to be there and I could restore from them. The moral being that you should check that restoring works for you too if you use this method!

© Copyright Quentin Stafford-Fraser