Save Time Machine backup to a network share on another computer

Home / Save Time Machine backup to a network share on another computer

Save Time Machine backup to a network share on another computer

Don’t have a Time Capsule or an external hard drive permanently attached to your Mac?  You can still save a Time Machine backup to a network share on another computer, whether it’s another Mac, a Windows PC or a network hard drive.

Time Machine in OS X Mountain LionTime Machine is a great built-in feature of Mac OS X that automatically builds a backup of your files.  As your files change, Time Machine automatically creates a new copy of the changed files only, providing an efficient and effortless backup solution.  As your backup copies become older, Time Machine removes the obsolete copies but retains the most recently changed versions of your files.

By default, Time Machine only allows you to configure backups to an Apple Time Capsule, or to an external hard drive that is attached to your Mac.  This isn’t necessarily always practical but as is the Apple way: keep simple things simple and complex things possible; we can still make use of Time Machine to maintain a backup over a network share.

Here’s how to save Time Machine backup to a network share

To do so, we need to create a disk image that Mac OS X can mount as a disk to read and write files to, as if it were an external hard drive.  That disk image can then be saved on another computer or storage drive in the network share location.  By then telling Time Machine where to find the disk image, Time Machine can then use it for backup purposes.

Create the Disk Image

Create a new image with Disk Utility

Our backup will actually be an image that OS X will mount to read/write data to.  The size of the file will only be as large as the data contained within, up to the maximum size that you set below.  So for instance, if you create a disk image of 100 GB but only store 20 GB worth of data inside, the actual image file will only use around 20 GB of physical space.

  1. On your Mac, open the Disk Utility application.  You’ll find this under Utilities in your Applications folder.  Click New Image from the top menu.
  2. In the Save As box, type a name for the file that will be saved to your network share, for instance, MacBook Air Backup.
  3. Select the location to save the disk image from the Where box.  This could be the network share you intend to use, or you could save the image to your Mac and then move the file over to the network share manually later.
  4. In the Name box, type an easily identifiable name to recognise the disk when it is mounted to your Mac as a drive, such as Backup.
  5. Enter custom size for Disk Image in Disk UtilityClick on the Size list and choose Custom.  Make sure that you enter a size for your disk that will be large enough to hold your data but also a realistic size that will fit on your actual disk!  For my backup, I entered 150 Gb.  Then click OK.
  6. Leave Format as Mac OS Extended (Journaled).
  7. If you would like your backup to be saved encrypted, select an option from the Encryption list, otherwise leave this as none.  Personally, I choose to use 128-bit encryption.
  8. From Partitions, make sure that Single partition – Apple Partition Map is selected.
  9. Select Sparse Bundle Disk Image from Disk Utility menuThen, from the Image Format list, select sparse bundle disk image.
  10. Click Create.  If you selected encryption, you will be prompted to create a password at this stage.
  11. Quit Disk Utility

At this point, if you didn’t save the disk image to the network share, move the file that has been created to that location now.

Mount the Disk Image as a Drive

Sparse Bundle Disk Image file in OS X Finder

Open the Finder and browse your network to the location where you have stored the disk image that we just created.  You will see the image file with the name that you entered with a .sparsebundle suffix.

Double click this file to mount the image as a drive.  You might notice an icon appear on your desktop, with the disk title you gave it, like Backup.

Configure Time Machine

We’re nearly done!  We just need to configure Time Machine where to find the backup drive that we created and that’s it!

  1. Open Terminal.  You’ll find this in Utilities within your Applications folder.
  2. Type in the command sudo tmutil setdestination /Volumes/{mounted-disk-image} where {mounted-disk-image} is the name of the mounted disk on your desktop, i.e., Backup.
  3. Press Enter
  4. If you’re asked to enter your password, type this and press Enter
  5. Then type exit, press Enter
  6. Quit Terminal
  7. Open System Preferences
  8. Click Time Machine

Once Time Machine opens, it should automatically have selected the disk image that we created.  If it hasn’t, click Select Disk… and choose it from the list.

And that’s it!

Time Machine performing backup to network share in OS X Mountain LionDon’t forget to turn Time Machine on and after a few moments, it will automatically begin creating the initial backup.  After this initial backup has been created, Time Machine will recognise which files have changed and will create subsequent backups of changed files only.

If you have any issues, leave a comment below and I’ll try and help you further.

Leave a Reply