CrashPlan backups

CrashPlan is a cloud backup service we use to back up personal working machines and the experimental ones. It backs up files, not the whole disk, i.e., files can be recovered but you won't be able to restore your whole system.*

Everyone with a HUID can install CrashPlan on any number of computers.

* We assume that a total machine failure is a rare enough event so backing up files is enough. You can use OS-specific backup software to make additional backups to an external drive or one of our shared drives.

Restore on a new/wiped computer

code42 restore is slow and it doesn't backup .git folders so the main thing we'll try to do here is to avoid doing a code42 restore :-)

Before an expected restore, like before wiping

  • Make sure you have a second alternative backup. Either to the lab's NAS or your own external drive. If you don't have one yet, you can set it up using the TimeMachine on MacOS or File History on Windows.

  • Write down your username: you'll need to use exactly the same one if you have to do the code42 restore.

  • Check that all your git repositories have no uncommitted changes and are pushed to GitHub using git status.

  • Make one more backup (I know, I know).

    # All of the below should be done in a folder outside of your user folder.
    # Files from that folder should then be copied to external storage (shared
    # drive, usb drive, external HDD, etc.)
    
    # Save lists of installed applications
    ls -1 /Applications > installed_apps.txt
    ls -1 ~/Applications/ > installed_apps_user.txt
    
    make_extended_list="system_profiler SPApplicationsDataType"
    echo "# Result of \`$make_extended_list\`" > installed_apps_extended.txt
    eval $make_extended_list >> installed_apps_extended.txt
    
    # Save list of brew packages - applications you installed using `brew install xxx`
    brew list > brew_packages.txt
    brew leaves > brew_leaves.txt
    
    # Tar your user folder
    output_path="$(pwd)"/"$USER".tar
    cd ~/..
    # brew install gtar if gtar is missing
    # "-H posix" should preserve precise timestamps
    # Look through your user folder and exclude more folders if necessary
    gtar -c -f "$output_path" -H posix --exclude="Library" --exclude="Box Sync" /Users/"$USER"
    # Check that the archived files are identical to the files in your user folder.
    # The expected results is no output at all.
    gtar -d -f "$output_path"

0. Restore using Time Machine or whatever other non-code42 solution you used

If that fails:

0.1 Create a new user with the same exact name as your old user

That's what code42 recommends. And here is a description of what can happen if you use a different username (ignore the page title). I am not entirely sure what exactly that page says but it sure sounds like changing the user name isn't safe.

0.2 Untar your user folder tar

Untarring will overwrite

brew install gtar
cd ~/..
gtar -x -f <path-to-the-tar>

1. Install code42 and log in

Follow #installation and #1.-log-in above.

2. Select "Replace existing device"

Choose your old/pre-wiping computer name.

3. Restore your files

If you are switching to a new computer, do not use the old one once you start the restore to avoid version clashes.

  1. (if this was planned and not an emergency restore) Untar

  2. Click "Transfer files".

  3. Select the folder(s) you want to restore. It might be just your user folder.

    Note: the restore process is slow. If you need some files earlier - select only them first and come back to this step once that is done.

  4. Click "Restore".

  5. Click "Continue".

  6. Connect your computer to power and set it up so it doesn't go to sleep.

  7. Work on the new computer, don't use the old one to avoid version conflicts.

  8. If a Duke login page opens all of a sudden - feel free to ignore it.

  9. Check on the restore the next morning or when you feel like it.

  10. Wait, check again, repeat.

4. (if you didn't have <user>.tar) Recover git repositories

Go into the working folder of each git repository you had and clone the repository into it using a trick here. Alternatively, just delete the working folder and clone it again. But be aware that this way you will lose all your ignored files which you might need (think .wav files).

Page Status: needs updating

Status details: Duke-related keywords found on the page.

Last updated by ?? on ??/??/??.

Last updated