Before you continue, I recommend checking out 7-zip, a free, open source alternative to PKZip. The only major feature missing from 7-zip 4.65 is the ability to do incremental backups. Check out my article on using 7-zip for backups for more information.
PKZip is a very handy backup tool. Put two hard drives in your machine and back one up to the other. Or buy an inexpensive USB external hard drive. I use two BUSLink 80gig USB 1 drives that I picked up for a reasonable price. I used to back my machines up to tape. Then I figured out how to use PKZip for backups, and I haven't gone back.
Here are some PKZip command line options that are useful for backups:
-add=arch" clears the archive bit on files that are backed up
-dir=root" includes directories relative to the root
-attr=all" backs up hidden and system files
-span=732954624" avoids the 4gig file size limit of FAT32 by breaking the zip file into 699MB pieces (perfect for cutting to 80min CD)
-excl=c:\directory" allows you to exclude specific directories from the backup. Combined with the "@" symbol, you can store a long list of exclusions in a separate file.
-max" enables maximum compression, it may take more time, not a problem if you let this run overnight
Make a "backup.bat" batch file which starts
up pkzip with the options you like. Use the "@" feature
of pkzip which lets you bring in lists of files from a text
file. You can use "
-email@example.com" to pull in exclusions
from a file called "backup.exc". In that file would be a list of
things you don't want backed up. Directories like Temporary Internet Files,
and file extensions like *.obj are good candidates for this file.
You can also do the same
for "inclusions". Instead of specifying a list of directories
you want backed up in the batch file, use "@backup.inc" which pulls
in the directories
to include from a file called backup.inc. Here's a simple example:
pkzip -add=arch -dir=root -firstname.lastname@example.org backup.zip @backup.inc
backup.inc is a list of what is to be backed up:
While backup.exc is a list of what should not be backed up:
Temporary Internet Files
Note how a leading star is required when specifying directory paths.
This is just as powerful as any tape backup software. A little less user friendly perhaps, but tape backup software tends to be less than friendly anyways. This is probably better.
To do incremental backups (backing up only those files that have changed since the last backup), you must first do a full backup using "-add=arch" to clear the archive bits on all the files that are backed up. Then when you later want to do an incremental backup, use "-add=incr". You can also do a differential backup using the "-add=-incr" option.
My current backup batch file has this line in it:
pkzip -span=732954624 -attr=all -max -add=arch -dir -excl=@c:\system\backup.exc %1 @c:\system\backup.inc
If you ever need to restore, you'll want to be aware of the following options:
-dir" - Extracts all directories.
-times=all" - Restores the file times and dates.
-mask=none" - Restores the file attributes (hidden, system, read-only).
You can restore a portion of the backup, like a single directory, like this:
pkzip -ext -dir -times=all -mask=none backup.zip "Documents and Settings\Administrator\My Documents\*"
Although the -span option gets around the 4gig file size limit for FAT32, it does not fix the 4gig freespace bug over the network. You will find that pkzip cannot reliably backup to a drive over the network. There is a simple workaround. Instead of running pkzip on the machine that is being backed up, run pkzip on the machine that is storing the backup files. This will slow your backup down quite a bit, but at least it will work.
PKZip 4.00 has a limit of somewhere around 64k files per archive. To get around this you'll have to split your backup into pieces or upgrade to PKZip 5.00. Another alternative is to try 7-zip. I'm currently evaluating it and it appears to be pretty effective. See below.
The safest way to make sure everything is backed up is to backup everything. Unfortunately, this is wasteful of time and space since a large portion of your hard drive is probably dedicated to Windows itself, temporary files, and (if you are software developer like me) pre-compiled header files and other intermediate compiler things that are a complete waste of space in a backup.
I could probably write at length on this topic, but I don't have time at the moment. I'll leave you with some pointers to things that you might not think of backing up that are very important.
Fortunately in Windows XP, M$ finally got it right. Almost everything that really needs to be backed up is in "c:\Documents And Settings", so you only need to back that up. Temporary files do live there, so you may want to exclude those to save space. Some applications still don't use this directory as M$ intended so you may need to do some digging for application-specific data.
In Windows 95/98/ME, if you commonly only backup the data on your hard disk to save backup media space, don't forget to backup the following directory:
Many applications like Outlook Express keep their data in this directory. Also, if you have multiple user accounts set up on your machine, backup the following directory:
A separate "Application Data" directory is in there for each user on the machine.
http://www.tugzip.com - TUGZip is freeware and might be capable of doing backups. I've not tested it, however.
<- Back to my Technology pageCopyright ©2003-2009, Ted Felix