Backup and Restore

If you aren’t backing up your home computer on a regular basis, you are either insane, don’t care about your data, or have never lost a hard drive before. Did you know hard drives have a 100% failure rate — every hard drive will eventually die. It’s not a question of “if,” but “when.” To date, I’ve been lucky; I haven’t had any critical drives die on me yet, but I did something earlier today that sure made me glad I run nightly backups.

It all started this morning when I noticed my website was running slow. Like, really slow. When I checked TaskManager on my server I noticed that every time I (or anyone else) visited robohara.com, my server was crawling to a stop. A closer look at TaskManager showed each time someone visited robohara.com, PHP-CGI.EXE was launching over 100 times. I can’t tell you for sure when this started, but I just noticed it today. I’m sure it hasn’t been doing it for long.

I went and checked all my other websites, but none of them were experiencing the same problem. Thinking something had gone wrong with my theme, I switched themes. Some themes experienced the same problem; others didn’t. Rather than spend a week tracking down the problem, I decided the easiest and quickest solution would be to simply switch to another theme. But before trying that, I decided I would upgrade WordPress.

Upgrading WordPress is a super simple process. You copy files into your WordPress directory and run them — that’s it. I’ve upgraded WordPress dozens of times before, so imagine my surprise with this upgrade failed. My browser filled with database errors, and when I refreshed robohara.com, I got one, ominous error. No posts found.

Fearing I had just lost four years worth of posts, I panicked briefly before remembering — hey dummy, this is why you do nightly backups! The first thing I did was restore my WordPress directory from last night’s backup. That took less than a minute. I then restored my SQL database (where WordPress stores its posts), also from last night. Again, success. I restarted my website was back up and running. With a freshly restored copy of my website I was able to switch to a different theme, one that was not causing the problem, and call it a day.

Back when my computer was simply filled with games and all my important documents were stored on floppies (shudder), backups weren’t that critical. These days, my entire life is online. Every phone number, every important document, and practically every photograph I have of my family is stored on my computer. Hard drive failure at this point in time would be devastating. Depending on how much data you need to back up, DVDs may or may not be a viable solution for you; it’s not for me at this point — I’m backing up too many machines too often these days. Instead, I recommend picking up a USB hard drive and performing nightly backups to that. If you go on vacation, the drive can easily be taken with you or stored somewhere else where fire or thieves could not access it. Losing my WordPress blog would have severely sucked, but losing ten years worth of digital photos would suck infinitely worse.