Thursday, December 1, 2016

Effective Backup Strategy

Losing a hard drive, can ruin your life.  Well, maybe not that dramatic, but the loss of a drive can create sleepless nights struggling to recover lost files and get back to where you the instantaneous moment before the tragedy.  Like most mechanical devices, invariably there are signs things are about to go sideways.  One of my favorite scenes in Bruce Almighty is when Jim Carey is following the flat bed truck, all pissed off trying to get around it wondering why God is not giving him a "sign."  Warning, danger ahead, do not pass; all the signs ignored, he passes the truck and winds up in the bay.  Supposedly that scene was shot in San Diego.  Bad sectors, unusual noises, degrading performance are all signs that should be revealed before it gets to that point by adhering to a monthly schedule.

Structure!  On the first of every month, do a little preventative maintenance on your workstation or laptop.  I lost a hard drive and discovered my hap-hazard cloning was not actually working because of large-disk-drive bug in the utility I was using.  I never actually tested the cloned drives; duh.   Then the unthinkable happened, I lost a drive and thought my world was coming to an end. I finally had to accept I could not recover the drive and it was 100% my fault.

I called my co-lo provider and asked them for advice, they are linux guys and recommended Clonezilla.  Clonezilla  is an open-source, linux based utility that does several types of cloning, by device, file system, network.  Using Clonezilla and incremental backups to "the cloud."  I will never lose anything ever again.  Windows backup/restore is a royal pain, its too complicated, it is slow and requires a bootable device and is it really working, there is a better way.

An effective backup strategy includes taking periodic cold-backup of the drive, a clone, with daily incremental backups to the cloud.  I use Cox Business for my incremental backups, but there any many choices out there.

For an effective backup strategy you need at least 2 drives of the same size.  I primarily use Seagate 2TB Barracuda drives, but I also have a 2TB Western Digital in the mix of four drives.  You can use varying drive sizes, but that adds a level of complexity with a possibility of error and the goal here is to make this process simple, quick and reliable.   This is for windows, but it works with any operating system.  Windows licensing uses several devices to determine if you have a new machine or simply made a change to an existing setup.  It will not require re-licensing a windows installation cloning a drive.

Before beginning label each hardrive with its serial number, you will need this to ensure you source and target drives are correct.  You will also need a bootable Clonezilla CD.

On the first of every month do the following:


  1. Run chkdsk from a command windows on all partitions.  This will detect any file system problems.  There is no point cloning problems.  If anything is detected it must be repaired here if possible before cloning, if not possible still continue.  
  2. Run cleandisk or bleachbit to cleanup your temp directories and updates. (optional)
  3. Run harddisk vendor utility to scan the drive.
  4. Shutdown the PC
  5. Connect the target drive from the oldest drive in your rotation to your pc.  (for a laptop use a USB hardrive adapter)
  6. Boot into clonezilla.
  7. Select device to device clone.
  8. /sda is the source, /sdb is the target map /sda to the serial number of the drive you are currently using.  If you make a mistake you will wipe out your last thirty days.
  9. Skip all the file system checks, we all ready did that in the first three steps.
  10. Include sector 0 or the boot sector in the clone.
  11. It takes about an hour to do 2tb drive.  Device-to-Device is create an exact sector by sector clone from the source to the target drives.
  12. When completed, swap the drives.  This is a critical step, it shows that your clones actually work.  On a laptop best you can do is confirm the drive with the usb adapter, or open it up and swap the drives out.