How to have Mac OSX’s Time Machine feature in Windows XP with Unison.

As much as I dislike the whole Caffè Latte sipping, ribid fanboy culture around Apple, I can’t help but be jealous of some of the cool features that Apple has in their computers.

Time Machine is ultra cool. Being able to go back in time to an eariler version of a document is extremly useful to have. Unless you have a Windows 2003 server at home, the Shadow Copy service is not available to you.

With one great little open source program called Unison however, you can mimic this great backup feature on your Windows XP system.

Here’s how you do it:

1. Get the Unison Windows text binary from this site. The version that I used was unison-2.10.2d-win-text.exe. You should rename the file to Unison.exe instead.

2. Find a place to backup your data. Either a local folder, another computer’s shared folder or a NAS like FreeNAS will do. For example: \\server\backupstore.

3. Create a path on the backup location that will store the backup files. You should have a sub folder for the folder that you intend to backup. If you are backing up ‘My Documents’ for example: \\server\backupstore\backups\my documents.

4. Create a folder where the pervious file versions will be stored. For example: \\server\backupstore\backups\oldversions.

5. Run Unison once to create the c:\Documents and Settings\username\.unison folder.

6. Create a backup.prf file with the following information in the c:\Documents and Settings\username\.unison folder:

# Unison preferences file

#Source and destination root paths.
root = c:\documents and settings\username\my documents
root = \\server\backupstore\backups\my documents

# Helps out a lot on Windows
fastcheck = true

# Don’t synchronize permission bits
perms = 0

# Place new files at the top of the list
sortnewfirst = true

#Backup everything and keep up to 5 old versions of a file in the oldversions folder.
backup = Name *
maxbackups = 5
backuplocation = central
backupdir = \\server\backupstore\backups\oldversions

#Force non conflicting updates to go through and ask no questions.
batch = true
auto = true

7. Create a batch file called unisonbackup.bat with the following line:
c:\path to unison\unison backup.prf.

8. Make a scheduled task to run the batch file once day or every few hours depending how often you want to check for file changes.

When the script is executed, all the files from the source root will be synched with data from the backup root location. If a file is changed, the old file will backed up to the old version folder. It’s not as fancy as Apple’s Time Machine feature but it will at least provide a way to go back in time to retrive old copies of a file that you need.

This entry was posted in Cool Software and tagged . Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *