Windows 2008 DFS Replication Issue

This happens after you install hotfix 2663685 http://support.microsoft.com/kb/2663685

It changes the behaviour after a dirty DFSR shutdown so that there is no longer an automatic restart, instead it stays down allowing you to do whatever backups you may need to do, then you run a WMI command as per the article to restart it.

Word of warning - applying this hotfix on a cluster means it effectively isn't highly avaialble as a failover will leave DFSR down on the node taking over. You can adjust this by a registry setting. Personally, I'm about to undo this hotfix across our estate as it's more trouble than it's worth, DFSR falls over and doesn't come back online til we arrive in on Monday, and the backlogs just grow and grow


The easiest way to get this up and running again is to go to your Event Viewer, and go to Applications and Services Log > DFS Replication. Look for the event 2213:

enter image description here

The exact command you need to run is in there.

Additionally, to revert DFS-R back to its original settings, run this:

wmic /namespace:\\root\microsoftdfs path dfsrmachineconfig set StopReplicationOnAutoRecovery=FALSE

I just ran into this similar issue but hotfix 2663685 was not my problem. In my case dfsrdiag would work for some of my replicated folders but not all of them. The replicated folders were distributed over different drives.

Long story short is that DFSR would not process the replicated folder because of a corrupted database. You can verify the drive is missing with this command. It should list all the drives you have DFSR Folders on.

wmic /namespace:\\root\microsoftdfs path dfsrvolumeinfo get volumepath, VolumeGuid

Mine was missing one of the DFSR Volumes. It will probably still be listed in the config so you can check with this command if your not sure if any are missing.

wmic /namespace:\\root\microsoftdfs\ path dfsrVolumeConfig get *

Also check C:\Windows\debug\dfsr*.log for other messages about the drive not being ready or not being able to read the serial numbers.

To resolve it I had to stop DFSR and delete/rename the database. It then started to sync and after a while of rebuilding the commands finally worked.

  1. Open a cmd prompt as system(I hate to modify permissions of "system volume information" doing this you can avoid that. Google how to do it.)
  2. Go to the drive with the corrupt database .ie "D:"
  3. cd "system volume information"
  4. cd "DFSR"
  5. rename Config\Volume_.XML Config\Volume_.OLD
  6. rename Config\Replica_.XML Config\Replica_.OLD
  7. rename database_ database__OLD
  8. net start dfsr
  9. dfsrdiag pollad

https://social.technet.microsoft.com/Forums/windowsserver/en-US/95873844-af76-4b7d-a4ee-2224a2e243cc/distributed-file-system-replication-dfsr-the-content-set-was-not-found-error?forum=winserverfiles&prof=required

Also DFSR logs are way to detailed and limited to 1000 log files by default. Please change the log level to something sane because once you hit 1000 DFSR just stops.

wmic /namespace:\\root\microsoftdfs path dfsrmachineconfig set debuglogseverity=3

https://blogs.technet.microsoft.com/askds/2009/03/23/understanding-dfsr-debug-logging-part-1-logging-levels-log-format-guids/


Since it does work on a different volume then D, I would assume it's related to the D volume, and reformat that volume (or just delete and recreate volume) or permanently move the replica to a different volume. If there was truly something wrong with DFSR itself, it wouldn't work regardless of the replica or volume.