You can use the following command to get and set the DFSR primary member.
Get which DFSR member is primary member
Dfsradmin Membership List /RGname:<replication group name> /attr:MemName,RFName,IsPrimary
Set the primary member for a replication group
dfsradmin Membership Set /RGName:<replication group name> /RFName:<replication folder name> /MemName:<primary member> /IsPrimary:True
Run "dfsrdiag pollad" to update Active Directory configuration.
Showing posts with label DFS-R. Show all posts
Showing posts with label DFS-R. Show all posts
Thursday, May 3, 2018
Monday, September 19, 2016
DFS-R stopped replication Event 4012
If the DFS-R service
stopped replication and you can see Events with ID 4012 in the DFS Replication
Log, you can do the following steps to resolve this issue.
First have a look into the event 4012:

In the log we can see that the server has been disonnected for 101 days. To resume the replication, we have to change MaxOfflineTimeInDays to a value above 101 or rebuild it.
I will show you how to set the value to resume the replication. Just do the following steps:
- Set MaxOfflineTimeInDays in cmd:
wmic.exe /namespace:\\root\microsoftdfs path DfsrMachineConfig set MaxOfflineTimeInDays=102
- Restart DFS-R service in cmd:
net stop dfsr && net start dfsr
After that you can check the DFS Replication log and you will see that the replication resumed. It´s normal that it will detect conflicts (Event 4412).
Next Steps:
To prevent this issue, you can create a Powershell script that search for Event 2213 is logging the ROOT cause for Event 4412 that will be generated 60 days later. If an event was found it will send out an email. The Powershell script will be executed on a daily base in a schedule task, so you will be informed if this event happen on your server.
First have a look into the event 4012:
In the log we can see that the server has been disonnected for 101 days. To resume the replication, we have to change MaxOfflineTimeInDays to a value above 101 or rebuild it.
I will show you how to set the value to resume the replication. Just do the following steps:
- Set MaxOfflineTimeInDays in cmd:
wmic.exe /namespace:\\root\microsoftdfs path DfsrMachineConfig set MaxOfflineTimeInDays=102
- Restart DFS-R service in cmd:
net stop dfsr && net start dfsr
After that you can check the DFS Replication log and you will see that the replication resumed. It´s normal that it will detect conflicts (Event 4412).
Next Steps:
To prevent this issue, you can create a Powershell script that search for Event 2213 is logging the ROOT cause for Event 4412 that will be generated 60 days later. If an event was found it will send out an email. The Powershell script will be executed on a daily base in a schedule task, so you will be informed if this event happen on your server.
Subscribe to:
Posts (Atom)