Welcome to TechNet Blogs Sign in | Join | Help

Ask the Directory Services Team

Microsoft's official Enterprise Platform Support DS blog

News

  • Disclaimer: All postings are provided "AS IS" with no warranties, and confer no rights. This weblog does not represent the thoughts, intentions, plans or strategies of Microsoft. Because a weblog is intended to provide a semi-permanent point-in-time snapshot, you should not consider out of date posts to reflect current thoughts and opinions.

    Locations of visitors to this page
What is the purpose of the 'Deleted' folder in DFSR?

Hi, Ned again – and surprisingly, talking about DFSR!

From time to time a customer will ask us about the Deleted folder in a Distributed File System Replication (DFSR) content set. It never seems to have anything in it. Not to mention we have a folder called ConflictAndDeleted and there definitely are deleted files in there.

image

So what gives?

The Deleted folder only comes into regular use when the option 'Move deleted files to Conflict and Deleted folder' is unchecked under Advanced for a given replicated folder membership in DFSMGMT.MSC, like below:

image

When this is unchecked, a deleted file is no longer copied into ConflictAndDeleted, nor is the ConflictAndDeletedmanifest.xml file updated. Instead, the file on a downstream partner is temporarily moved into the Deleted folder while the DFSR database and USN are updated, then deleted directly from that folder.

Unless that checkbox was turned off and a massive quantity of deletes was processed, it's unlikely you will ever see files in that folder for more than a moment. But we do have a way to see things happening on the file system faster than a speeding bullet – Process Monitor.

If we run Process monitor on a downstream server and configure our filter to ‘path -> begins with -> the replicated folder’ we can see what goes on under the hood with minimal chaff.

image

Then we can just delete a file on an upstream server. Here’s what happens when I delete ‘Readme.doc’ on the upstream server and the deletion request reaches my downstream partner:

image

That’s kinda chaffy to read, so let’s cut to the important parts:

1. The file e:\datarf\readme.doc is moved to e:\datarf\dfsrprivate\deleted\ReadMe.doc-{AC759213-00AF-4578-9C6E-EA0764FDC9AC}-v141560

Perfmon Log entry:

"2:57:15.5042328 PM","Dfsr.exe","2260","SetRenameInformationFile","E:\DataRF\ReadMe.doc", "SUCCESS","ReplaceIfExists: True, FileName: E:\DataRF\DfsrPrivate\Deleted\ReadMe.doc-{AC759213-00AF-4578-9C6E-EA0764FDC9AC}-v141560"

(Do you remember from previous blog posts what the long GUID refers to? It’s the server that originated the deletion. The file is being mangled here with GUID and version because this is what would have been written into ConflictAndDeleted to maintain uniqueness.)

2. Then the file is deleted

Perfmon Log entry:

"2:57:15.5056190 PM","Dfsr.exe","2260","SetDispositionInformationFile", "E:\DataRF\DfsrPrivate\Deleted\ReadMe.doc-{AC759213-00AF-4578-9C6E-EA0764FDC9AC}-v141560","SUCCESS","Delete: True"

In case you’re curious, the Deleted folder cannot be… deleted. If you do so, the DFSR service will simply add it back in the next it’s restarted.

So we covered a bit of DFSR and a bit of Process Monitor. I hope you found this interesting. Perhaps in the comments section someone wants to take a guess at what the Installing folder is for?

- Ned Pyle

Posted: Monday, August 18, 2008 3:02 PM by NedPyle
Filed under:

Comments

Marcel Heek said:

Ned,

My guess would be that when the file is replicated (either complete or by using RDC) the file is stripped with alternate filestreams (CRC info) and plced in the installing folder prior to moving it into the replicated folder, possible to give DFS-R and USN journal time to record the actions performed.

Good job on giving us all this info on DFS-R, great tool.

regards,

Marcel Heek

# August 19, 2008 2:48 PM

Matt Johnson's Technical Adventures said:

The Old New Thing : The implementation of iterators in C# and its consequences (part 3) Notes from a

# August 21, 2008 3:22 PM

NedPyle said:

You were just about spot on there Marcel. :) As the file is decompressed from staging (which may take some time if quite large), there needs to be a place to do the work safely without interrupting use of the real file. Once the decompression is done and everything is unmarshaled, it can be moved from Installing to the final destination instantly.

# August 25, 2008 1:46 PM

maweeras said:

So the install folder is the same as pre-install in FRS days?

# September 8, 2008 3:26 PM

NedPyle said:

Exactly like that, yes.

# September 8, 2008 4:08 PM

The Storage Team at Microsoft - File Cabinet Blog said:

Hello, everyone Below you have a compilation of some very interesting blog posts from AskDS and Extreme

# September 11, 2008 1:08 PM

Dario IT Solutions Blog said:

Check out the following posts: What is the purpose of the 'Deleted' folder in DFSR? DFSR and

# September 12, 2008 10:04 AM
Anonymous comments are disabled
Page view tracker