Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Several users are using offline folders to refer to a server we want to decommission... actually the server is already offline and people have pending updates to this share.

What is the best way to move these cached files to a new server with a new name without losing the new data?

share|improve this question

2 Answers 2

Oy... so i've gone through this before and it's not the most fun. Basically, you need to go offline for each client computer. Then copy the offline files to a safe location, and finally purge the offline folder cache (follow the instuctions linked here http://support.microsoft.com/kb/230738). Then you can copy the file back and everything should be in sync.

Your other option is to create a cname record (guessing here) to point to the new server name, but the path must match verbatim. Eaither way, you'll still want to get that old servername out of the sync list and purging the offline DB is the only way I know how to do it.

FYI, you might want to point your offline files at a DFS share, even if you don't have a second target. This way if you need to move to a new FS down the road, it's controlled at the DFS level and won't affect your clients.

share|improve this answer
    
Using DFS is an incredibly understated piece of this. If you are using offline folders it's important to use DFS to avoid this exact issue. –  Jim B Jun 5 '12 at 17:33
up vote 3 down vote accepted

Windows XP and Windows 2003 have a utility called CSCCMD /MoveShare that can move files from one UNC to another for you:

/MOVESHARE:\Server1\Share \Server2\Share – Use this switch to move files and directories from one share to another share in the cache. This option is useful if the target of offline files has moved and if the local cache now must point to a new location. For example, use the following command:

 CSCCMD /MOVESHARE:\\MyServer\MyShare \\MyServer1\MyShare1

This utility is not supported on Windows Vista and newer, however a COM and WMI interface have been created. For an overview of what is possible, review this COM overview.

VBScript should be able to call this Windows 7 API to move files from one location to another.

In order to used that API you need get VBScript to make WMI invoke a method. I found a few Code samples on this MSFT blog, ... especially this code sample will get you started writing VBScript that renames a file location

Note: In order to run this code you need to have the Desktop Experience installed.

share|improve this answer
    
interesting find, I've never heard of that before. Have you tried it out yet? Anyway, you probably still want to pursue a DFS share, it will make your life a lot easier down the road. –  Eric C. Singer Jun 6 '12 at 15:17

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.