How to force DFS replication resync RRS feed

  • 问题

  • Hello,

    We have 3 Windows server 2012 file server, all files in share drive will replicate from server1 to server2 and then replicate from server2 to server3. we find that there have some folder out of sync, can we force resync these folder through DFS replication?

    2015年8月26日 7:03


  • Hi,

    If some files are out of sync, you should first check if replication is working as expected.

    If DFSR is still working but just missed some files, you may need to check if they have specific attributes such as Temporary.

    We can use Fsutil to check the un-replicated file for Temporary Attribute on the File.

    For example:

    fsutil usn readdata c:\data\test.txt

    Major Version : 0x2 
    Minor Version : 0x0 
    FileRef# : 0x0021000000002350 
    Parent FileRef# : 0x0003000000005f5e 
    Usn : 0x000000004d431000 
    Time Stamp : 0x0000000000000000 12:00:00 AM 1/1/1601 
    Reason : 0x0 
    Source Info : 0x0 
    Security Id : 0x5fb 
    File Attributes : 0x120 
    File Name Length : 0x10 
    File Name Offset : 0x3c 
    FileName : test.txt
    File Attributes is a bitmask that indicates which attributes are set. In the above example, 0x120 indicates the temporary attribute is set because that is 0x100 and 0x20 (Archive) = 0x120.
    Here are the possible values: 
    READONLY 0x1
    HIDDEN 0x2
    SYSTEM 0x4 
    DIRECTORY 0x10 
    ARCHIVE 0x20 
    DEVICE 0x40 
    NORMAL 0x80 
    TEMPORARY 0x100 
    SPARSE_FILE 0x200 
    REPARSE_POINT 0x400 
    COMPRESSED 0x800 
    OFFLINE 0x1000 
    ENCRYPTED 0x4000 

    How to removing the Temporary Attribute from Multiple Files with Powershell:

    To remove the temporary attribute, we can use PowerShell which can be installed from here. After PowerShell is installed, please open Powershell prompt (Start, Run, Powershell or from the Programs menu) and run this command to remove the temporary attribute from all files in the specified directory, including subdirectories (in this example, D:\Data):

    Get-childitem D:\Data -recurse | ForEach-Object -process {if (($_.attributes -band 0x100) -eq 0x100) {$_.attributes = ($_.attributes -band 0xFEFF)}}

    Note: If you don’t want it to work against subdirectories just remove the -recurse parameter.


    Please remember to mark the replies as answers if they help and un-mark them if they provide no help. If you have feedback for TechNet Support, contact

    2015年8月27日 11:42