Crashplan headless linux

Install the linux client and backup engine

(As of the current release, java is included)

The link below may be out of date, so check the latest installer from their site as desired

wget https://download1.code42.com/installs/linux/install/CrashPlan/CrashPlan_4.4.1_Linux.tgz
tar -xzf CrashPlan_*
cd CrashPlan-install
sudo ./install.sh

Firewall Changes

To allow this system to receive backups, you'll need to open port 4242 as the CrashPlan docs specify. Here's a ufw app and rule.

sudo vim /etc/ufw/applications.d/CrashPlan

[CrashPlan]
title=Crash Plan
description=A Backup Server
ports=4242/tcp

sudo ufw allow CrashPlan

Connect Remotely (with a MAC)

    Install Normally

Stop the local service and backup your config file

sudo launchctl unload /Library/LaunchDaemons/com.crashplan.engine.plist
sudo mv /Library/Application\ Support/CrashPlan/.ui_info /Library/Application\ Support/CrashPlan/.ui_info.bak
   
Create a tunnel to the remote server's management port and echo the crashplan shared secret to the console

ssh -L 4243:localhost:4243 you@some.gattis.org
cat /var/lib/crashplan/.ui_info;echo

Echo that shared secret to your local config file then launch your local User Interface
  

# on the local mac
sudo su root -c 'echo <stringFromAbove> > /Library/Application\ Support/CrashPlan/.ui_info'
# Launch the local app from your GUI
# Logout from your SSH session when done

Restore your local service (on your MAC)

After you're done, mv your file back and restart the daemon

sudo mv /Library/Application\ Support/CrashPlan/.ui_info /Library/Application\ Support/CrashPlan/.ui_info.someServer
sudo mv /Library/Application\ Support/CrashPlan/.ui_info.bak /Library/Application\ Support/CrashPlan/.ui_info
sudo launchctl load /Library/LaunchDaemons/com.crashplan.engine.plist


 
Add Additional Memory

If you have more than 1TB of files, you should increase the memory. The guideline is 1024m per TB. Do this by editing the crashplan config file below and changing the SRV_JAVA_OPTS -Xmx parameter from 1024 to, say 3072.

sudo vim /usr/local/crashplan/bin/run.conf

SRV_JAVA_OPTS=... -Xmx3072m ...

Tune For Large Datasets

When you have many terabytes of files, you'll see performance slow to a crawl as the engine (seemingly) attempts to dedup everything you put in, even if it's an initial backup. You can alter this behavior by changing that setting.

sudo vim /usr/local/crashplan/conf/my.service.xml

<dataDeDupAutoMaxFileSize>1</dataDeDupAutoMaxFileSize>
<dataDeDupAutoMaxFileSizeForWan>1</dataDeDupAutoMaxFileSizeForWan>

After an initial backup, you may want to restore those to their original value.




Links


http://support.code42.com/CrashPlan/Latest/Configuring/Configuring_A_Headless_Client
http://support.code42.com/CrashPlan/Latest/Troubleshooting/Stopping_and_Starting_The_CrashPlan_App
http://support.code42.com/CrashPlan/Latest/Troubleshooting/CrashPlan_Runs_Out_Of_Memory_And_Crashes
http://networkrockstar.ca/2013/09/speeding-up-crashplan-backups/
Comments