Lets start out with our problem.
We have many desktops here at the office, and we want the user data replicated to the server so it’s included in the backups (Desktop, Documents, Pictures, Favorites, etc).
We used to use roaming profiles. Though the users were not normally allowed to roam from machine to machine. The upside was, it was easy to deploy a new machine to a user, and of course, we had a copy of their files on the server if their computer failed at any time. The downside, roaming profiles can cause logon/logoff events to take longer. Permissions can get screwed up, which will prevent the profile from synchronizing. Ever have a user complain that they deleted icons on their desktop just to have them magically reappear when they rebooted? Yea… So have we.
We ditched roaming profiles in favor of folder redirection in Vista/7. The upside, files are on the server and included in backup. The downside, you are now working only off the server. There are obvious delays when working with large files/projects.
That being said… Folder redirection with offline files works well for mobile users. As they are disconnected from the network the majority of the time. Therefore, they are working locally. When they connect, files sync, and are backed up. This was not a viable solution for desktop users on our LAN.
The solution? RoboCopy. It’s fast, free, simple to script, and can work with Volume Snapshots (vshadow). I tried a few others, but wanted a simple script that would mirror changed files, periodically, throughout the day.
This following document, I found to be a great starting point.
http://www.eggheadcafe.com/tutorials/aspnet/f6972828-1e81-4cd4-ae0c-36196a82ed25/workstation-open-file-bac.aspx
I downloaded RoboCopy, familiarized myself with the command line parameters, and wrote a simple script to copy some folders to my server.
Then I worked on implementing vshadow. It was a pain at first. Namely due to the fact that no single exe will work on all platforms. Theres one for 2003/xp, theres two for vista/7/2008 (x86/x64).
I downloaded the Volume Shadow Copy Service SDK 7.2, and started digging into it.
You’ll find the files you need in \Program Files\Microsoft\VSSSDK72\TestApps\vshadow\bin\… I referenced this article, which helped.
I wrote a script to mount a new snapshot, call my robocopy script, then delete the mount point. It errored on “‘dosdev’ is not recognized as an internal or external command“. Seems I’m missing another file. A quick google, and I picked dosdev up here.
Now I can take a snapshot, and mirror user directories to their folders on the server. =)
Here are the files I used.
Hope this helps someone.
p.s. the image, top-right, is a mozy.com t-shirt. i used to use mozyhome. however a good program, it doesn’t apply to this article 😉