RoboCopy is a free command line tool included with Windows Server 2003 Resource Kit Tools which speeds the process of moving, migrating and backing up data from point A to point B. Years ago, I moved away from nightly backup tapes and into the realm of external firewire drives - with RoboCopy as the heavy lifter. Ever have to restore a single file from a backup tape? Arrrggghhh. I'd rather be sitting in an Admin Committee meeting poking myself in the eye with a sharp stick. With external drives, the process is almost pleasant.
For each volume or directory that I want to back up, I simply enter a line in notepad and then save the whole thing as a batch file. Set the task scheduler to run the batch file on an admin machine at a particular time each day and/or night - and life is good. For behemoths like the Exchange Information Store and the SQL Database, those files are first backed up to a Network Attached Storage unit - and RoboCopy pulls those copies down in the middle of the night. That way, if we ever have to restore the megafiles, we can try it first straight from the NAS rather than the slower external firewire drive (or turtle-paced tape drive).
RoboCopy compares the source and destination files - and will only copy files that have changed since the last backup to that external drive. You can even set a switch to purge files on the destination drive that no longer exist on the source. Logging to the screen or to a text file is a snap - with an option to simply list the files that would otherwise be copied or moved (a handy way to test your scripts). The flexibility is unparalleled. A pretty comprehensive list of RoboCopy commands and switches are located HERE.
A pretty typical line in my backup batch file looks like this:
"G:\toolkit\RoboCopy \\Main\data\LIBRARY\DOCS\ E:\Main\data\LIBRARY\DOCS\ /E /XF *.tmp /A-:R /R:5 /zb /purge /np /LOG:E:\MAIN_BACKUP.txt"
The system first finds the RoboCopy executable ["G:\toolkit\RoboCopy"] then tells it to look at the source where all my documents are located [\\Main\Data\LIBRARY\DOCS\] and copy them to the firewire drive [E:\Main\data\LIBRARY\DOCS\].
The switches tell RoboCopy to:
- copy all subdirectories [/E]
- to exclude any tmp files [/EF*.tmp]
- to reset any read only files [/A:R]
- to retry copying the file 5 times if it is in use [R:5]
- to use restartable mode; if access denied use Backup mode [/ZB]
- to purge any files on the destination that no longer exist in the source [/purge]
- not to display the progess [/NP]
- and to log the job [/LOG:E:\MAIN_BACKUP.txt]
Terrabyte sized external drives at < $1000 a pop make backing up to disk the preferred method for small to mid-sized firms. What's more, we are able to test our backups on ANY Windows XP Pro machine (in the office, in my basement, or on any other XP machine out there). Plug in the firewire, run a quick batch file to map some of the directories to mirror our network drives and we can run Accounts Payable, Accounts Receivable, General Ledger, Time & Billing and Document Management in less than 3 minutes. Is it as smooth and fancy as the some of the online backup solutions? Nope - but it doesn't cost tens of thousands a year, either. I challenge any other backup solution to match the level of assurance we have that our data is safe and accessible.
And still - the usefulness of RoboCopy extends far beyond nightly backups. Whenever an attorney departs the firm, they typically seek to take all of their clients' files with them - as well as copies of any workproduct they created for other attorneys' clients. Giving them their own client files is pretty straight forward since our document management program (PerfectLaw) neatly stores all client and matter data in self contained directories.
But what about the individual files that the attorney created over a span of 10 years - for someone else's clients? Using Excel's external data function, we are able to create a quick SQL query against the document management database and pull a number of document fields directly into Excel - including the doc path, doc name, date, author, etc. Using one of my absolute favorite Excel functions (concatenate), we are able to create a RoboCopy command line for each and every file - then paste the text into Notepad, save as a batch file and fire for effect.
We once had an entire section depart the firm - and using RoboCopy, we were able to quickly dump out all of their files onto an external drive with MINIMAL effort. If the attorney was actually pleasant to you over the years, you could even do a couple concatenate and hyperlink tricks to give them a Excel spreadsheet linking to all of their documents and all contained on one neat little DVD.
In all, RoboCopy is an essential weapon within any law firm's IT arsenal. Because of its power and flexibility, you should have at least one member of your staff well versed in it's use.
1 comment:
I like it! Keep up the good work. Thanks for sharing this wonderful site with us.
»
Post a Comment