Thread: 10.4.3 bugs
View Single Post
Barto
Student extraordinaire
 
Join Date: May 2004
Location: Canberra, Australia
 
2005-11-11, 03:44

Say you admin an internet cafe, a public library, or any public computer. Create a new user, and make a backup of the home directory, then delete the contents of the original. Union mount the backup at the original home dir. Any changes made to the home directory is confined to the home directory (including new files, deleted files and modified files), which can be restored to the backup state by deleting the contents of the home directory. Any changes made to the backup (which might be hosted on a remote server and accessed by multiple clients) are reflected in the original in real time.

This does not work on Mac OS X for a couple of reasons. One, the /usr/sbin/mount_union executable is missing. This can be worked around by using disk images instead with hdiutil. Two, HFSX does not (or at least Mac OS X does not implement this) white-out files, where a file is created specifying the deletion of the original file. If the user erases the contents of the home directory, that erases the backup.

There are other ways to accomplish this of course (usually deleting the original and restoring from a backup at set intervals), but this does not update the mount point directory in real time, is less flexible, uses more system resources and is slightly more difficult.

The sky was deep black; Jesus still loved me. I started down the alley, wailing in a ragged bass.
  quote