Paul Henderson

Bit of my brain (and other people's) on the internet

Back up there a minute…

Well you may have noticed a hiatus in the blog for a while there – after an odd day of being Liam Byrne’s blog, unfortunately I lost most of the content from here. The bad news was I hadn’t taken any recent back-up. On the upside – I hadn’t blogged much and was able to retrieve many of the posts from Google’s cache.

But let’s turn this faux pas into something hopefully useful. Back-ups are boring, there’s no two ways about it. That is until you find out you haven’t got any, and potentially a lot of hard work has gone up in smoke (or electrons). Putting stuff on the web instead of your own computer is great, but you still need to have a copy of that data  somewhere else (backing up to the same webserver is no good if it lunches itself)

OK here are some rules and tips

  1. What to back-up?
    With something like Wordpress you have two lots of data, you need to back up both of these in case of emergency:

    • Files (just like on your desktop) which may be  uploads, themes, plugins – everything in the wp-content folder
    • Your database (usual MySQL)- this contains all your posts and pages. You can’t really access it directly but you can get the database to export a single plain text file which can rebuild itself (it contains the structure of the database as well as all the data) which can then be zipped up when it gets too big.
  2. How to back up?
    Automate, automate automate – You can just do a manual export of all your posts, pages, comments, custom fields, categories, and tags  (go to Tools>Export). The problem is that humans are rubbish at doing boring things regularly and faultlessly, computers are much better at it. Fortunately there are a fair few plugins to help with backing up WordPress. I’m using  two different ones

    They work by creating  file that is then emailed to you as frequently as you need it – you may need to create a folder on your webserver where these files are temporarily stored and then email it to something like a Gmail account which has plenty of space and you can file away until you need it…

  3. Test your back ups
    Finding out that your back-ups are useless or somehow corrupted is not best done when your blog has disappeared, so you need to test your back-ups by restoring them and checking that they work ok. If you’ve got a second blog then it’s better to do that than play around with your main blog. Because the files usually produced can be unzipped to plain text files you can have a quick check that they look ok in a text editor

If you’ve got any more tips then leave a comment.


Categorized as Resources

Leave a Reply