A tutorial that described how to automatically launch a backup script in Mac OS X when an external drive is mounted was published at MacResearch.org on Friday.
Mac OS X 10.4, Tiger, introduced a new daemon called launchd that replaces inetd, init, mach_init, and System Starter. By defining a plist, the user can create a process that watches for a volume to be mounted, then run a backup script. In the example, the UNIX command rsync was used to generate a full or incremental backup to an external volume. The basic rsync technique has been explained at MacDevcenter.
The tutorial was helpful in explaining the details of how Mac OS X launches daemons and applications. Itis also useful for those who want to see how Appleis more modern launchd compares to traditional UNIX mechanisms for starting up processes. Finally, for those who are unhappy with their current backup software, the tutorial, combined with the MacDevCenter link, reveals how system administrators and technical users can get control and roll their own backup procedure.