|March 18, 2002
I personally hate reading
articles about backing up your server because most of them are very theoretical
and throw in a lot of stuff that most people like you and I will never
need. I'm not going to buy a DAT drive with multiple tapes and then
do daily incremental backups and then a large weekly or monthly full backup.
And all that stuff about tape rotation and of course the rotation schemes.
Then they'll usually talk about buying expensive backup software, etc.
Don't get me wrong, backing
up is important and those articles are great for system administrators
who run large-scale servers, but they don't work well for us little guys.
So what do we do for backups? I'm not going to buy a tape drive,
especially when these days hard disks are larger than the tapes.
I'm not going to be able to follow a complex rotation cycle because I'm
But I do backup and I do
it regularly. This article attempts to show you how I personally
backup my server. Is it the best way? No. Is it the only
way? No. Should you follow what I do? Depends.
Then why the heck should you bother reading this then? Because it
works for me and maybe it'll work for you. (Maybe not) Nonetheless,
backing up your server is very important and I’ll show you how I do it
with a minimal amount of fuss. So there.
I won't be using tape drives
or data backup software, but instead, I’ll talk about backing up using
something almost everybody has, a CD-writer. If you don't have a
CD-writer, go buy one! Just kidding. CD-writers are pretty
cheap these days. I still remember buying my first CD-writer, it
was a Panasonic 8x read 4x write model. I paid $300 for the bare
drive. That writer was very reliable but wow it was expensive.
The downside of using a CD-writer is that each CD can only hold 650-750
Megs of data.
Why do you have to backup?
What's your main enemy concerning data loss? Would you be surprised
to find out that the biggest reason for data loss isn't hardware failure,
but instead operator error. That's right, YOU are the biggest threat
to your data. Okay, maybe your little sister pounding on the keyboard
might cause some data loss, but most data loss is caused by the owner/operator
when they are performing something routine. Then you hear “CRAP!
What did I just do!????” This is not to say that hardware failures
don't exist. But in general, hardware failure is not as common as
user error. Now that we know who are enemy is… (hehe, it's YOU)
First of all, on my server,
I classify my data into to types: stuff that doesn't change much and stuff
that changes quite a bit. For example, I store all my application
installation programs on my server so when I build a new computer, I can
install everything over the network. This saves me a lot of time
searching for CD’s, drivers, floppies, etc. I also store all my hardware
drivers there. This data doesn't change all that much and can occupy
a lot of space. Last time I checked, I had about 20 gigs worth of
install files. The stuff that does change more often is my website
data. The amount of data here is considerably smaller. I have
about 250 Megs for my website data. This is the data which I’ll update
or will automatically be updated when people post new messages in the forums.
These two types of data can
be backed up differently. The stuff that doesn't change much can
be backed up once and then you can not bother with backing it up again
until it changes significantly. My application installation files
don't change much, but they do grow larger, so as I add more application
installation files to my server, I just make sure to burn a CD to add to
existing collection of backup files. When you burn this data onto
CD’s, I recommend burning them uncompressed and unzipped. This way,
you can access the data from any computer and pull files as needed.
If you zipped all your data into one huge zip file and then parsed it so
it would fit on CD’s, then you try to access even a little bit of your
data, you would have to copy all the CD’s onto a computer, combine it into
a huge zip file, and then decompress it. All this just to get one
little file. If you keep the data uncompressed and unzipped,
it'll be much easier to access. You can also simply add to your CD
archive by burning the new data onto a CD.
Now let's backup the more
variable files, namely the web data for your website. I don't know
how much space your website data takes up, but most likely it's less that
what can fit on a CD or around 650-700 megabytes. This is why most
people do fine with commercial web hosting solutions that only have 10-20
megabytes. Just for info, this website takes up about 50 Megs.
If you have a lot of pictures or multimedia files, this can vary from site
Here is how I backup my web
data. I first have a backup directory.
Every week I copy the directory
on my server that contains my web data over to the backup directory on
my workstation computer.
I then add the current date
to the directory name.
Now I have the files on my
workstation. However, I won't burn it onto a CD yet. I’ll repeat
the process every week until the end of the month. At the end of
the month, I’ll have 4-5 different copies of the directory c:\Inetpub backed
up on my workstation. It may look like this:
Then I’ll burn the whole
thing onto a CD. Twice just to be safe. I’ll label the CD:
“March2002Inetpub Copy 1”
and “March2002Inetpub Copy 2”. Now I will have an archive CD of my
website for every week of a month on each CD.
Now let's talk about what
you just gained if you follow the above method. If your server hard
disk crashes on you, the maximum amount of data you lost will be worth
at MOST one week since you'll have each week backed up on your workstation.
If your server and workstation BOTH die on you at the same time (highly
unlikely), the maximum amount of data you lost will be worth at MOST one
month since you'll have each month backed up on CD.
If you have the time and
energy, you could modify the schedule above so that you copy the server
data over to your workstation every day and burn a CD every week.
This would be fine but it's too much work for me. A weekly disk backup
with a monthly CD backup is just all I can handle. I also like the
fact that you'll capture a weekly snapshot of your website. It's
nice to see a progression if you ever take the time to go back through
the CD and look.
A couple of notes on backing
up to CD.
So there you have it.
My lazy man's guide to backing up your data. You might think that
setting up a RAID 1 (mirroring) means that you don't have to back up your
data, but if your recall that most data loss is caused by operator error,
RAID isn't going to save you. If you have RAID, you still need to
Your data may or may not fit
on 1 CD, in this case, use more CD’s. I personally can't fit one
month's worth of backups onto 1 CD, but I can fit two weeks worth onto
a CD so I just use more CD’s.
Make duplicate copies of your
backups by burning two copies each time. This will save your butt
in case a blank CD has a defect or something.
Make a CD image of your data
on your hard disk first, and then burn the CD from the CD image.
Many times, website data is composed of a high number of very small files.
CD writers handle small numbers of large files fine. They don't do so well
with thousands or millions of tiny little files. By making a CD image
first, you'll turn those thousands of files into 1 big file which the CD
writer (and hard disk) like much better. You'll end up with less
coasters this way.
Label your CD’s! This
sounds like a no brainer, but I bet you that you have a bunch of unlabeled
CD’s hanging around. You know you do.
Store your CD’s in a safe place.
What good is backing your stuff onto a CD if it's not going to be treated
with care. Fine a nice dark closet or something for them. Don't
let them bake in the sun like your other CD’s.
I hope this article inspires
you to backup your precious data if you aren't already doing so.
What's the point of a webserver without data right?