Our LogicMonitor caught a Distributed File Service (DFS) alert:
Staging Folder For Replicated Folder Has Exceeded Its Configured Size
which leads to replication failure and that is bad.
When DFS was installed it was likely configured with the default 4GB “staging area” and in todays world that is unlikely to cut it.
The DFS Staging Area is just a folder on a Distributed File Service server that acts as the cache for files with changes that need to be replicated to other servers.
Microsoft says that your DFS staging folder should be larger than the 32 largest files on your shares combined. So if you have 10 files that about about 1GB each and 10 files about 100MB and 12 files about 50MB, your staging area should be set to about 12GB.
Fortunately Microsoft has a simple PowerShell tool to find and calculate that total for you:
$large32 = Get-ChildItem c:\\temp -recurse | Sort-Object length -descending | select-object -first 32 | measure-object -property length –sum
$large32.sum /1gb
If you want to know what those largest 32 files are, run this simple PowerShell command:
Get-ChildItem c:\temp -recurse | Sort-Object length -descending | select-object -first 32 | ft name,length -wrap –auto
For complete details on the size of the DFS Staging folder skim THIS Microsoft article.
To change the DFS Staging Area Size:
If you want to see what is waiting to be replicated by DFS:
Other than looking as the backlog report (explained above), there are three easy ways to make sure your DFS is working:
Put a new file in a share that is being replicated and see if it quickly appears at on the other DFS server
In theory DFS staging should clean itself up and delete replicated files automatically when it fills 90% of the DFS Staging Area. However, you may want to force it to clean up.
We have not tested this but it makes sense:
1- Open a CMD prompt as an administrator on the DFSR server.
2- Get the GUID of the Replicated Folder you want to clean:WMIC.EXE /namespace:\root\microsoftdfs path dfsrreplicatedfolderconfig get replicatedfolderguid,replicatedfoldername
3 – Then call the CleanupConflictDirectory method:
WMIC.EXE /namespace:\root\microsoftdfs path dfsrreplicatedfolderinfo where “replicatedfolderguid=”” call cleanupconflictdirectory
https://social.technet.microsoft.com/Forums/windows/en-US/d222264d-9ba7-4ece-9481-2069c5169d26/dfs-replication-database-is-getting-big?forum=winserverfiles
This website uses cookies.