Technical Notebook

Archive for February, 2012

Change tmp directory for CrashPlan on OSX

I have been an avid user of CrashPlan for quite some time, therefore I have dabbled in how to tweak it under the hood (especially in the case of Linux systems). Recently I had the need to move the tmp folder for Crashplan off my primary HDD and onto my secondary HDD. For the purpose of this article I will not go into why you might want to do this, that is up to you. However one issue I found was that there was no documentation anywhere describing how you would achieve this on Mac OSX Lion (and this should in theory work for any other recent version of OSX).

So, if you would like to have a custom temp directory for Crashplan on OSX perform the following steps:

  1. Back up your system… back up early back up often (I always like to throw this in).
  2. Do this ONLY if you know what you are doing, when you follow the next step if you don’t know what you are doing you can do permanent damage to your installation that may require a complete re-install to get around.
  3. Open a terminal and run ‘sudo bash’
  4. BackupĀ /Library/LaunchDaemons/com.crashplan.engine.plist
  5. EditĀ /Library/LaunchDaemons/com.crashplan.engine.plist and add the following lines after the line which specifies DCP_USER_HOME.
    <string>-Djava.io.tmpdir=INSERTTEMPDIRHERE</string>
  6. Stop the CrashPlan service
    launchctl unload /Library/LaunchDaemons/com.crashplan.engine.plist
  7. Start the CrashPlan service
    launchctl load /Library/LaunchDaemons/com.crashplan.engine.plist

Please note, if/when an update is pushed out by CrashPlan this may get overwritten so you may need to apply the fix at such a time.

Hope this helps someone else out at some point.

Stuart