DFS-R vs. BranchCache in Branch Offices

Find out whether you should use DFS-R or BranchCache.

John Savill

August 20, 2014

4 Min Read
folders

Q: Should I use DFS-R or BranchCache in my branch offices?

A: Because this question is becoming more common, I thought it would be worth pointing out the key differences between the two technologies.

The Distributed File System (DFS) provides a logical namespace that has a series of folders, with each folder having one or more folder targets that are shares on services. Adding multiple folder targets for a server provides resiliency from server failure; if one folder target isn't available, then clients are directed to an alternative target. In addition, DFS is site-aware and clients are directed to the folder target that's closest to them. When you have multiple folder targets it can be difficult to keep the multiple copies synchronized, which is where DFS-R is used. DFS-R is a replication technology that leverages remote differential compression to keep multiple targets synchronized. In a branch scenario, this would mean placing a folder target replica in the branch office and that branch office replica would then have a full copy of the folder. Even if the link between the branch office and the primary data center were unavailable, users would still be able to access the folder replica.

BranchCache is a very different technology. BranchCache works by having one user from a branch download the content from the server hosting the content. The content is BranchCache enabled, which means hash values are created for chunks of the data. When a second user downloads the same content, the user is sent the hash values that represent the data; that user acquires the actual data locally from the first user by sending out the hash values and in response receives the data. The user that wants to access the data needs to be able to communicate with the server hosting the data to get the hash values before BranchCache can be used. If the primary server is unavailable (e.g., if the link between the branch and the data center is down), then a user won't be able to obtain the data, even if it were available locally via BranchCache.

BranchCache has two types of functionality. In hosted mode, a server is designated as the BranchCache server. When users download data, they forward it to the BranchCache server; when subsequent users are sent hash values, they directly ask the BranchCache local server if the data is cached. In distributed mode, users receiving the hash values and then send out a broadcast on their local subnet asking if other machines have the corresponding data. The downside of distributed mode is that if someone downloads a large file but then disconnects their machine, another user would have to download the file again. This wouldn't be the case with hosted mode; hosted mode requires a server but also adds the advantage of supporting clients over more than one subnet.

A key difference at this point is that DFS-R has all the data within a folder target available locally (which means you need to know what data is required ahead of time and ensure it's replicated) and can be accessed even when the branch is disconnected from the primary location. BranchCache only has the data that has been used by clients at the location (or data that has been pre-cached) but can only be accessed providing the primary server can be contacted, which means the branch can't be disconnected from the primary location. If you need data available even if the connection to the primary data center is unavailable, you need to use DFS-R. If you simply want to provide caching to improve performance for frequently accessed data, then BranchCache is a great solution.

You also need to consider the amount of data that's involved. With DFS-R, all the data in a folder target will be replicated, which would be a lot for a large share. Even after initial synchronization (which could be performed out-of-band), there would be a lot of replication traffic if the data changes frequently. Compare this with BranchCache, which would only keep data that was used by people as it was accessed--noting that the first person to access the data would have to wait as it was downloaded from the primary location.

DFS-R only works with file server data, whereas BranchCache can also work with protocols such as IIS to enable web content caching.

Hopefully this information will help you decide whether to use DFS-R or BranchCache.

About the Author

Sign up for the ITPro Today newsletter
Stay on top of the IT universe with commentary, news analysis, how-to's, and tips delivered to your inbox daily.

You May Also Like