Solutions to backing up macOS user data

Backing up user data can be a time consuming and risky task. Even though it almost always works out well, even one mistake can be very costly for IT, both in terms of reputation and money.

More and more, organizations are therefore leaving responsibility for backing up files to the user. Users handing their machines in to IT, should expect to have them wiped, exept in special cases.

For this to work, IT could:

  • Use cloud services such as Google Backup & Sync, File Stream or DropBox and make sure everyone knows they need to store their files there.
  • Use open source software such as OwnCloud to set up their own cloud sync. If you have tried the Mac version, I would love to hear from you in the comments below.
  • Tell users to place their documents on a traditional file server, if they have a personal space and are used to using a file server.

Sometimes IT still needs to perform manual backups. There could be any number of reasons for this, including missing recovery partitions and files that have not been synced.

  • Migration Assistant will work for some organizations, but it will copy the old user over, which isn’t what you want in many use cases.
  • Carbon Copy Cloner is one of the best alternatives for backups. You can set up a dedicated Mac as a backup station, put the old machine in target disk mode and transfer files to a backup area or dedicated RAID using Thunderbolt. Disable SafetyNet and tick Don’t preserve permissions in Carbon Copy Cloner.
  • Copy only the user folder to the backup drive, then copy the contents of visible folders inside it to correspondong locations in the new user folder. Some files obviously are not well suited to copying back, and not necessary either. The contents of the Library folder, the Micosoft User Data folder and Applications should not normally be copied over.
  • The above backup routine could probably be scripted or made into an application for a gentler and less intelligent (sometimes less is more) backup/restore than what Migration Assistant and iCloud Drive offers.
  • Using an SSD as the backup drive will speed things up a lot.
  • You could also download Carbon Copy Cloner on a target machine and transfer files directly from a previous one, then place them in their proper locations.
  • The first time a user starts Photos or iTunes, they might be asked for permission to rectify some inconsistencies and update the library. Doing so should be safe.
  • If iCloud Drive has been enabled, backup can sometimes be a challenge. Not only can the special files Apple use in iCloud-enabled folders cause problems with manual restores, there can be more files than there is really space for on the machine, as some reside only in iCloud.
  • If iCloud Drive is enabled and some files are no longer present locally, start by connecting the machine to a fast, cabled connection. Liberate space by backing up some files and deleting them, then disable the option Optimize Mac Storage in the iCloud drive preference pane. Or download files from by clicking on the download button next to files in Finder. This could take a while, depending on how much data you have to download and your connection. You may need to liberate space as you go. If changing machines, you probably need one with a larger drive or an external drive for additional data.
  • Check out Cirrus, a utility from Howard Oakley, for managing iCloud.
  • Consider disabling iCloud Drive Desktop and Document sync using a configuration profile.

Worth noting:

  • Apple has a support document explaining how to resolve permissions issues in the home folder. Here’s a script for Mojave:

    #!/bin/bash
    loggedInUser=$( /usr/sbin/scutil <<< "show State:/Users/ConsoleUser" | awk -F’: ‘ ‘/[[:space:]]+Name[[:space:]]:/ { if ( $2 != "loginwindow" ) { print $2 }}’ )
    sudo -u $loggedInUser chflags -R nouchg /Users/$loggedInUser
    diskutil resetUserPermissions / $loggedInUser
    exit 0
  • Data Rescue 5 from Prosoft Engineering is a sturdy tool for undeleting files and recovering data from corrupt drives.