2024-12-03

DFS-R 斷線過久不再進行複寫問題

EventLog DFS Replication 中出現 Event ID 4012

The DFS Replication service stopped replication on the folder with the following local path: C:\DFSR\Folder. This server has been disconnected from other partners for xxx days, which is longer than the time allowed by the MaxOfflineTimeInDays parameter (60). DFS Replication considers the data in this folder to be stale, and this server will not replicate the folder until this error is corrected. 

To resume replication of this folder, use the DFS Management snap-in to remove this server from the replication group, and then add it back to the group. This causes the server to perform an initial synchronization task, which replaces the stale data with fresh data from other members of the replication group. 

下指令:

查詢 MaxOfflineTimeInDays 設定值:
wmic.exe /namespace:\\root\microsoftdfs path DfsrMachineConfig get MaxOfflineTimeInDays

將它改為大於上述 Event Log 中提到的 xxx 值
wmic.exe /namespace:\\root\microsoftdfs path DfsrMachineConfig set MaxOfflineTimeInDays = 999

這樣他就會繼續複寫,等複寫恢復正常以後再把數值改回 60
不過,如果 DFS 是設成 Active/Standby 方式 (只有 Enable 一個 Target,其他複寫對象是 Disable 禁止存取) 的話,砍掉重新復寫可能比較快

沒有留言:

張貼留言