RSS2.0

What about TimeMachine?

Monday, April 21, 2008

In my last post on backup strategies, I completely neglected mentioning TimeMachine. So, I have decided to devote an entire post to it. For those unfamiliar, TimeMachine is a backup feature in Apple's Mac OS X 10.5 "Leopard" operating system. TimeMachine has some good and interesting features. To start off with, it's heavily integrated into the OS, automatically executing hourly or when a disk is connected to backup your entire disk to another drive. The application uses hard links to save space for incrementals, and keeps hourlies for a day, dailies for a week, and weeklies for a month. The system will automatically delete the oldest backup if it needs to recover space for the latest (after alerting the user). Furthermore, TimeMachine has the famous, and often criticized, "time warp" interface which shows your present disk in the foreground, with your previous snapshots disappearing into the endless black hole. Essentially, underneath the unnecessary eye candy, are instances of the regular Finder interface. You can flick back and forth between snashots and present, fully browse the, and even use Spotlight to search for a specific file. You can restore an entire snapshot or a specific file. Additionally, the Leopard start-up DVD allows restoration of a TimeMachine snapshot.

All of this seems fantastic, and indeed it generally is. However, TimeMachine is lacking a few features and exhibits numerous bugs that keep me from wanting to use it. TimeMachine only supports HFS+ formatted target disks or disk images. It can use an internal partition, an external USB disk, and a USB disk connected to an Airport Express (called an AirDisk) only. No backing up to another system or server, which means I can't use TimeMachine to backup to a ZFS-based storage pool (even if it has a HFS+ disk image residing on it). TimeMachine also doesn't support delta-transfer, which means if a large file changes, it copies the entire file as opposed to just the bits that changed (like rsync does). One potential plus that TimeMachine has going for it is its use of Leopard's FSevent API to dynamically see changes on the disk without having to scrub the entire filesystem at each backup looking at modification times like every other backup solution does (including rsync). This should allow relatively instantaneous backups, cutting out time a typical program takes to scrub. I use the would "potentially" because it doesn't really work like it should. For unknown reasons, TimeMachine is incredibly slow. It takes forever once started, seemingly stuck on "preparing backup" before files even begin to copy (reminiscence of a scrub). Once files start copying, they go slowly with frequent pauses in the backup stream. Literally, the initial backup of an 80GB disk connected via USB 2.0 could take upwards of 5-6 hours. I've had subsequent backups, even ones with less than 100MB to backup, take upwards of an hour (mostly on the "preparing" stage). Furthermore, I have had numerous problems where TimeMachine refuses to backup to its backup store, and the only fix is to all of your backups and start fresh. Unfortunately, deleting all of the files (including hardlinks) off of an HFS+ disk takes forever (hours and hours), so I recommend reformatting the entire partition/drive or deleting or recreating the disk image. In fact, I recommend just using disk images altogether!

Personally, I find it a pain to have to connect a disk to my laptop to do a backup. If so, I'm only likely to backup a few times a week (if that), which entirly defeats the purpose. To fix this, I've decided to connect my USB drive to my Airport and use it as an AirDisk. Recently, Apple added support to use an AirDisk like its TimeCapsule product. Again, this is tightly integrated. TimeMachine creates a sparse image on the AirDisk, and automatically mounts it whenever a backup begins and unmounts it when finished. This is fantastic! However, my PowerBook uses 802.11g (no n for me yet), so I'm stuck with extremely slow wireless transfers. This further exaggerates TimeMachine's general sluggishness I mentioned earlier. Even connecting via gigabit ethernet, backups are still slow. The worst problem lies in browsing snapshots via the TimeMachine interface, which is so slow over 802.11g its almost unusable. Finally, an AirDisk or USB drive are not redundant, meaning a crash would destroy all backup data (making TimeMachine not an enterprise backup solution).

I really like TimeMachine, but because of its slowness and buggy operation, I'm left searching for another backup solution that offers me some more flexibility (thus, my last post). I do, however, think TimeMachine has a very bright future! Apple will be tweaking it with Leopard point updates, and may very well eradicate the bugs I've experienced and speed up its general sluggishness. Hopefully, it will! One thing I'd really like to see, is snapshot support in the Finder without having to open the TimeMachine interface (such as previous version in the contextual menu). Furthermore, its very possible that in future OS X versions, TimeMachine could support delta-transfers and even ZFS!!! With these feature additions, FSEvent used to its full potential, combined with greater scheduling and target drive flexibility (including network drives), TimeMachine would truly be a world-class backup product I would relish coming back to.

0 comments: