Back to MacInstall
Apple's Time Machine automatic backup software works very well using an external hard drive directly connected to a Mac. Things get complicated when using it on the network, though.
Backing up Time Machine over the Network
The only supported network device is Time Capsule, but it is possible to run time Machine on unsupported shares such as Samba. The most detailed instructions are Making Time Machine work with the ReadyNAS, but they apply to most any system. You can also store a sparsebundle on a external disk directly attached to your Mac which makes it easy to duplicate the entire volume.
My sparse-timemachine.sh script automates the process of creating the sparsebundle disk image on your local machine. Then run this in Terminal:
defaults write com.apple.systempreferences TMShowUnsupportedNetworkVolumes 1
Log out and back in, mount your sparsebundle, and it should appear as a drive in System Preferences->Time Machine (for a local disk, just choose the parent disk and Time Machine will automatically use the sparsebundle).
Warning: This can unfortunately lead to a problem situation where your sparsebundles try to fill more space than your drive has.
Restoring from Time Machine
Note: some operations are painfully slow over the network. It is faster to restore from a locally attached disk when possible.
Time Machine Network File Restore
With a sparsebundle
- Mount the sparsebundle (you may need to mount the network share first)
- Right-click the Time Machine application and choose "Browse Other Time Machine disks..."
You should see your backup in Migration Assistant too.
With a network mount of a drive with Backups.backupdb
mkdir /Volumes/TimeMachine mount -t afp afp://uwsig@sigmacback.biostr.washington.edu/LaCieBiggest /Volumes/TimeMachine/
It will show up as an alternate disk in the Time Machine application, but not in Migration Assistant. (from MacOSXHints 10.5 Restore from network share Time Machine backups)
Full Restore from Time Machine Network Share
- Boot from the installer DVD. Choose “Options…” to get the Utilities menu
- Utilities > Disk Utility to partition the disk the way you like it
- Utilities > Restore System from Backup… If your Time Machine backup set appears, then restore away. While there’s a button here to connect to a remote disk, that option wasn’t clickable for me. So we’ll have to mount our network volume manually.
- Utilities > Terminal Run this command to mount your backup volume manually (substitute your username, password, and so forth):
mount -t afp afp://username:password@hostname/ShareName /Volumes hdiutil attach /Volumes/ShareName/foobar.sparsebundle
- Utilities > Restore System from Backup… and you should now be able to choose your Time Machine backups.
(from Full Disk Restore from Time Machine Backups - Over the Network)
Time Machine Server
To make a locally connected external disk drive available as a network backup drive, the drive needs to be mounted at boot. If it isn't, it won't be visible over the net until someone logs in.
In other words, local drives aren't mounted until someone logs in, and that's a bad thing if you need to use the drive for backups. Unless...
On the server, launch Terminal and enter the command:
sudo defaults write /Library/Preferences/SystemConfiguration/autodiskmount AutomountDisksWithoutUserLogin -bool true
to force the server Mac to mount its external disk at boot. Then it's visible without anyone needing to be logged in.
On the client side, automount can mount a network drive at boot, but Time Machine wants a drive on the Desktop; a drive mounted by automount does not mount on the Desktop.
Here's the work around. First, mount the network drive by hand via Finder->Go->Connect To Server. Use the server address afp://hostname/volumename. The host name can be a FQDN, IP address, or short name (if the host is in /etc/hosts). The volumename is the name the server uses when it mounts the drive locally.
After the drive is mounted on the Desktop, you can make it mount automatically to the Desktop at login via Apple Menu->System Preferences->Accounts; Click on User; Unlock; Select the Login Items tab, and drag the backup disk from the Desktop to the Login Items. Afterwards, the network drive will be mounted when you login, and Time Machine will be happy.
(wrb: 20080425)
