Main Page
 The gatekeeper of reality is
 quantified imagination.

Stay notified when site changes by adding your email address:

Your Email:

Bookmark and Share
Email Notification
Project Cache
Purpose
The purpose of this documentation is to provide tips on removing a disconnected (possibly removed) file server on the network that hosted the applicationHost.config along with other files from web servers with a new file server, and, (2) forcing the web servers to begin using the new file server for the files instead of being "stuck" using the locally cached offline files of the disconnected file server.

Recently I found myself in the situation where the applicationHost.config was being shared among web servers and the file server went down and could not be recovered (luckily there was another in place but not "plugged in" to the web servers). The Shared Configuration on the web servers were updated to point to the new file server and the new file server was setup for offline files (so the web servers would cache the neccessary files in their local offline files cache); no sweat, right?

As it turned out, the applicationHost.config was modified on the new file server but none of the changes could be observed. The web servers were "stuck" referencing the offline files cache of the disconnected file server even though the new file server was in place, the Shared Configuration in IIS7 was updated, and the new file server had been setup for offline files (not only as needed itself) as well as the web servers.

This is where the fumbling around began (see section below "Assumptions That Did Not Work"). Countless hours later a solution was found (see section below "Getting a New Offline Files Cache to Work").

Assumptions That Did Not Work:
This section documents the assumptions that were made which did not aid in (1) removing the disconnected file server from the offline files cache on the web servers, and, (2) getting the web servers to recognize the new file server to cache files for the offline files cache. This could be humorous reading.

(Enlarge)
  1. The first false assumption was that of going to Offline Files and deleting the offline copy. That did not remove the disconnected file server's cached files on the web server.

(Enlarge)
  1. The second false assumption was interpreting Microsoft Documentation regarding the Desktop Experience (here) in that it would help manage, aka "delete", the offline files.
  2. The Desktop Experience - to get Sync Center - (in hindsight) was of no use and if you install it you get some "bonus" applications installed as well such as Windows Defender.
  3. With the Desktop Experience installed, it was investigated to see if it could do the trivial task of removing the disconnected file server's cached files on the web server.

(Enlarge)
  1. Sync Center allows you to see the offline files but there's no way to get rid of the disconnected file server.

(Enlarge)
  1. So, let's go back to the Offline files pane and disable offline files. The assumption here is, might as well purge all of it and rebuild only what is current.

(Enlarge)
  1. Why look, now the server has to be rebooted; good thing it was taken out of the cluster just incase a reboot was needed.

(Enlarge)
  1. After server reboot and going back to the offline files pane, it shows that there's no offline files. Could this be it?
  2. I enable offline files.

(Enlarge)
  1. Sync Center shows that there's no offline files. Could this really be it?

(Enlarge)
  1. Let's go back to the offline files pane. It says offline files are enabled but not active so a reboot is needed. Let's reboot again. I love rebooting servers.

(Enlarge)
  1. Why look there! Oh, wait. All the offline files I had falsely assumed where gone are still there. It would seem that getting rid of offline files is like trying to get rid of a dark fungus.
OLD SCHOOL
  1. It's time to shift thinking to "old school".
  2. Did a lot of research and found there is a handy command-line tool called csccmd.exe available with Windows Server 2003 here. Since we're shooting in the dark here, let's download it and see if it will work.
  3. As suspected, that tool (for x32) would not work on Windows Server 2008 x64. Well, at least there's a piece of software to add to the archive incase I need to deal with an ancient Windows Server 2003 system.
  4. Found some good documentation for csccmd.exe that you can read here.
  5. Also found some documentation on modifying the registry from the command-line you can read here.
OLD SCHOOL
  1. A little more "old school" thinking lead to locating the offline files location on the hard drive of the web server. Surely the files could be deleted or modified.
  2. The offline files physical location was found at c:\windows\csc\Server-Share-Namespace. Unfortunately you will not be able to do anything without some "changes" to the server being done.


Getting a New Offline Files Cache to Work:
This section documents the un-intuitive method that must be done in order to (1) remove the disconnected file server from the offline files cache on the web servers, and, (2) getting the web servers to recognize the new file server to cache files for the offline files cache.

(Enlarge)
  1. Time to bust directly into the registry. Good thing the server has been removed from the cluster. I've got a feeling that the server will have to be rebooted. At least once.
  2. Would hate to make a mistake here and lock up the entire server so it becomes an expensive paper weight.

(Enlarge)
  1. Let's make a new entry under "Computer\HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\CSC\Parameters" called "FormatDatabase".

(Enlarge)
  1. Now modify that new entry.

(Enlarge)
  1. Now modify that new entry so it has the value of 1.
  2. And, reboot the server. Did I mention I love rebooting servers all the time?

(Enlarge)
  1. After reboot, let's look at offline files.
  2. Then, looking at "View your offline files" it only shows the new file server.

(Enlarge)
  1. Drilling down reveals that nothing is actually being cached (although offline file sharing is enabled on the new file server). This is okay.

(Enlarge)
  1. Open file explorer and navigate to the folder on the new file server.
  2. Right click and select "Always Available Offline".

(Enlarge)
  1. The icon on the folder should indicate it has been set for offline files.

(Enlarge)
  1. Let's go back to the offline files pane and click "View your offline files".

(Enlarge)
  1. Why look! The files off of the new file server are, indeed, in place.
  2. Now it's time to put the server back into the cluster.


About Joe