Time Machine backups for Mac OSX 10.9 to a Debian GNU/Linux server on the network

Disclaimer: I know absolutely nothing about Mac OSX, and my experiences so far have been pretty frustrating.

So I wanted that a Mac laptop on my home network do its backups on a separate server. Apple normally recommends an Apple router with an Apple hard drive and other closed expensive Apple perceptions of the world. However, most systems allow you to backup to an external server, using their internal backup system.

In short, I

  • installed netatalk ("apt-get install netatalk" on Debian, version 2.2.5 as of this writing);
  • created a standard unix account for that user, with password;
  • created a directory /home/johndoe/TimeMachine for that user (with files owned by that user);
  • used the following configurations for netatalk:

File: /etc/netatalk/AppleVolumes.default

/home/johndoe/TimeMachine  "TimeMachine"         allow:johndoe      options:usedots,upriv,tm

File: /etc/netatalk/afpd.conf

- -mimicmodel TimeCapsule6,106 -ipaddr -noddp -uamlist uams_dhx.so,uams_dhx2.so -setuplog "default log_warn /var/log/afpd.log"

NB: in the above, I made netatalk bind specifically, to avoid binding public network interfaces, but presumably you are running a firewall anyway.

File: /etc/default/netatalk

# Legacy stuff. Make sure it is disabled:

Now, from the Mac laptop, go to the finder and connect the network drive:

  • Open the Finder
  • Menu: "go" -> "connect to network drive"
  • Enter the IP address of the server and connect, it should ask for username and password.

Now go in Time Machine and select your network drive.

If your server is on the same network segment as your client machine, it can use Avahi/Bonjour to detect the server. If not, like me, just connect the drive first from the Finder.