There are quite a lot of useful information out there how to use a network share as destination for time machine. However I would like to add my own howto which also includes encryption oft the image.

I use this setup for a while now at home and at work. At work we use a x86 solaris box with samba and ZFS (at home i use linux and samba on ext3). If a user connects to a share a snapshot is automatically taken – if something goes wrong with a backup we can rollback. This works absolute flawless. So we have a network based backup for time machine with encryption.

Enter the following on the command-line (start Terminal):

defaults write com.apple.systempreferences TMShowUnsupportedNetworkVolumes 1
  • Now mount the image share via finder
  • Next open a terminal and enter the directory you mounted the share (e.g. /Volumes/image
  • Now open Time Machine Preferences and select the network share
  • issue a ls -la until you see a file with the endening sparsebundle and copy the name.
  • open time machine Preferences and under change disk select none.
  • ensure that in the mount directory no sparebundel exists any more and delete the file .<your mac address> – you need to execute a chmod +w in order to delete that file
  • now open disk utility from the Utility folder under Applications
  • select New image now paste the sparsebundle filename – remove .tmp inside the filename
  • set the properties to this values:

diskutil

  • Encryption: select encryption – you need to provide a password and check the Store password in keychain box!
  • Create the image on your desktop – don’t worry it won’t be that big since it is growable 🙂
  • unmount the new create sparsebundle
  • Encryption: open Keychain Access under Login locate the key for the sparsebundle and copy it into the System Key chain
  • Now copy this file to your image share
  • open Time Machine Preferences and klick change disk
  • again select the image share
  • enjoy