Apr 17, '03 09:57:00AM • Contributed by: tcurtin
- Using Disk Copy, create a New Blank Image of custom size (I made mine 300mb, but you can always copy the files to a new bigger image later), format Mac OS Extended, encryption AES-128. Name it SecureDisk or something and stash it somewhere you'll remember it. In my case, its in ~/Documents/SecureDisk.dmg. First, we'll copy the Mail data folders...
- Make sure Mail.app isn't running and SecureDisk is mounted on your desktop.
- Using the finder, navigate to ~/Library (Apple-N, click the Home button, open Library)
- Copy the Mail folder into SecureDisk
- Move ~/Library/Mail to the trash
- Open up a terminal window and enter the following commands:
% cd ~/Library % ln -s /Volumes/SecureDisk/Mail .
The ln -s command makes a UNIX link (basically the same as an alias) pointing from your ~/Library folder, where Mail.app will normally look for all of its files, out to the secure disk, where you'll be keeping them from now on. For some reason, making a standard MacOS alias won't work here - you need to use the terminal.
- Now we'll do the same thing with the mail preferences, so those are saved too:
- Using the finder, navigate to ~/Library/Preferences (Apple-N, click the Home button, open Library, open Preferences)
- Copy com.apple.mail.plist from the Preferences folder into SecureDisk/Mail
- Move the original from com.apple.mail.plist to the trash
- Then, again opening a terminal window:
% cd ~/Library/Preferences % ln -s /Volumes/SecureDisk/Mail/com.apple.mail.plist .
Again, ln -s works, but making a normal alias doesn't.
- Last but not least, we'll copy Mail.app into the disk too:
- Using the finder, find Mail.app (probably in /Applications) and copy that into the top level of SecureDisk.
- Move the old copy to the trash
- If you have Mail.app in your dock, pull it out, then drag the newly-moved one to the dock in its place.The reason for doing this is, if SecureDisk isn't mounted when you go to start Mail, the finder will be smart enough to mount the disk first (if the folders are on the disk image, but the application isn't, Mail will start but will be very confused...)
Once a week or so, I start up Disk Copy, choose File/Convert (Apple-K), open the SecureDisk.dmg file, save it with image format compressed, encryption AES-128, name it SecureDiskBackup.dmg, and then use the Finder's File -> Get Info (Apple-I) to set it Locked. Someday soon I'll make a script to automate that backup process - any kind souls with more AppleScripting experience want to paste the code here? Burn the backup to CD, copy it to another drive, whatever suits you, and you now have any important documents encrypted, backed up, etc!
Enjoy!
[robg adds: Though I haven't tried this, one caveat to keep in mind is that if a system update tries to update Mail, it may not work (as it won't find it /Applications). I'd recommend putting the application back in /Applications prior to running any updates.]
