Create your own TimeCapsule Backup Device with a Raspberry Pi

Home  >>  Projects  >>  Create your own TimeCapsule Backup Device with a Raspberry Pi

Create your own TimeCapsule Backup Device with a Raspberry Pi



Full Instructions Coming Soon!

  1. Download Rasbian (Jessie Lite or w/Pixel)
  2. Use Win32 Disk Imager to write Rasbian “.IMG” file to MicroSD Card (
  3. Boot RaspberryPi 3 with MicroSD Installed
  4. Update sudo apt-get update

  5. Run through basic Raspberry Pi Config, Expand File System and Reboot
    1. Sudo raspi-config
      1. Enable SSH (Advanced Options)
      2. Define Hostname (Advanced Options)
      3. Set Language and Regional Options
      4. Change Password
      5. Expand File System
  6. Format the Drive for EXT4 (in GUI I Used gparted) **add more info, install gui, tightvncserver)
  7. Create mount folder, add to fstab, and mount ( (more)
    1. Create Mount Point: sudo mkdir -p /mnt/timemachine
    2. Add to fstab using the following 3 commands:
    3. Mount the drive:

    4. Confirm drive has been mounted and proper size is shown with “df -h”
    5. Apply permissions:

  8. Install Netatalk (Source)
    1. sudo apt-get install build-essential devscripts debhelper cdbs autotools-dev dh-buildinfo libdb-dev libwrap0-dev libpam0g-dev libcups2-dev libkrb5-dev libltdl3-dev libgcrypt11-dev libcrack2-dev libavahi-client-dev libldap2-dev libacl1-dev libevent-dev d-shlibs dh-systemd
    2. sudo apt-get install avahi-daemon libc6-dev libnss-mdns (should be installed from above, run to make sure)
    3. sudo git clone
      cd netatalk-debian
      debuild -b -uc -us
    4. run “cd ..” to get back to the directory containing the .deb files created by the prior command and verify they are there with “ls -a”
    5. sudo dpkg -i libatalk18_3.1.10-1_armhf.deb netatalk_3.1.10-1_armhf.deb
    6. Confirm no errors by running the following command: sudo netatalk -V
  9. Create Time Machine User Account
    1. sudo adduser –home /mnt/timemachine timemachine
      sudo chown -R timemachine:timemachine /mnt/timemachine
    2. Set password for time machine user: sudo passwd timemachine
  10. Configure Netatalk for TimeMachine
    1. Make a backup of current Netatalk config: sudo cp /etc/netatalk/afp.conf afp.bak
    2. Run “sudo nano /etc/netatalk/afp.conf” and add the following to the bottom of the file:
    3. Modify the /etc/nsswitch.conf
      1. sudo pico /etc/nsswitch.conf
      2. Add “mdns4” and “mdns” to the line that starts with “hosts:”, so that it looks like this:
        hosts: files mdns4_minimal [NOTFOUND=return] dns mdns4 mdns

  1. Configure the Avahi service
    1. Create the file
      1. sudo pico /etc/avahi/services/afpd.service
      2. Past the following contents and save the file:

        <?xml version=”1.0″ standalone=’no’?>
        <!DOCTYPE service-group SYSTEM “avahi-service.dtd”>
           <name replace-wildcards=”yes”>%h</name>
  2. Start the services and set them to run at boot
    1. Start services:
      1. sudo service avahi-daemon start
      2. sudo service netatalk start
    2. Set them to run at boot
      1. sudo systemctl enable avahi-daemon
      2. sudo systemctl enable netatalk
  3. Configure OSX to backup to the new “PiMachine”
    1. To be continued (browse network, select PiMachine, Connect as timemachine/timemachine, go to
    2. time machine and go and setup as normal.

Comments are closed.