JP Vossen on 22 Nov 2011 19:54:31 -0800


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

Re: [PLUG] Incremental backup via cron


Date: Sat, 19 Nov 2011 12:33:17 -0500
From: Paul Walker<starsinmypockets@gmail.com>

I'm running an Ubuntu box via Linode where I host 7 or 8 websites. I'm
currently doing global SQL dumps twice daily via cron and would like to do
incremental backups of the whole /srv directory at the same interval. I've
experimented using git but I have a feeling there are better tools out
there. I'd like to backup twice a day and then copy everything down to a
local machine once a day. Do folks mind sharing their backup strategies?

Since you are pulling to local (presumably trusted), if you don't want to roll your own, take a look at BackupPC (http://backuppc.sourceforge.net/). Once you set it up with SSH keys, it Just Works, and have a reasonably nice web GUI. All backups appear "full" even when they are incremental. It uses rsync, with the hardlink trick, and does *file level* (not block level) de-duplication.

I do at least /etc on all my machines no matter where they are (Linode hosted, laptops, whatever) and may do more depending on the machine. It works great for me and the ability to go back in time has saved my butt more than once.


> I'd rather use command line tools that I can invoke via cron.

You can sort-of do this, but you neither want nor need to. You run it as a daemon on your "local machine," configure it to talk to the remote machine(s), set some intervals in the configs, and then just forget it until you need it.

I have to admit that I found the initial setup a bit tedious, but that was years ago and I only ever touch it when adding/retiring a machine, or doing Debian major version upgrades. I can provide sample configs, config & t-shooting tips on or off-list as needed.

Later,
JP
----------------------------|:::======|-------------------------------
JP Vossen, CISSP            |:::======|      http://bashcookbook.com/
My Account, My Opinions     |=========|      http://www.jpsdomain.org/
----------------------------|=========|-------------------------------
"Microsoft Tax" = the additional hardware & yearly fees for the add-on
software required to protect Windows from its own poorly designed and
implemented self, while the overhead incidentally flattens Moore's Law.
___________________________________________________________________________
Philadelphia Linux Users Group         --        http://www.phillylinux.org
Announcements - http://lists.phillylinux.org/mailman/listinfo/plug-announce
General Discussion  --   http://lists.phillylinux.org/mailman/listinfo/plug