Like the server-side
configuration, the BranchCache feature must be enabled on Windows 7
clients. To enable this feature in Distributed Cache mode, there are two
methods. The first method is via Netsh. For example, run a command prompt (Run As Administrator) and execute:
netsh branchcache set service mode=DISTRIBUTED
Executing the previous
command not only turns on and configures BranchCache, but also
configures Windows Firewall with the appropriate rules to allow
BranchCache to operate in this mode.
Needless to say, running a Netsh
command is not the most efficient way of turning on BranchCache. That
is why most people will use the second method for configuring
BranchCache on clients in Distributed Cache mode, which is a GPO. Use
the following steps to complete this task:
Enable the Turn On BranchCache GPO setting (Computer Configuration\Policies\Administrative Templates\Network\BranchCache).
Enable the Set BranchCache Distributed Cache Mode GPO setting (Computer Configuration\Policies\Administrative Templates\Network\BranchCache).
Enable and configure the BranchCache for Network Files GPO setting (Computer Configuration\Policies\Administrative Templates\Network\BranchCache).
Here, the latency value that determines when the network files aspect
of BranchCache will kick in must be specified. The default is 80.
latency value can be set to 0, which forces BranchCache for network
files (SMB) to be turned on all the time. Also, when you configure
BranchCache via GPO, it overrides any configuration that is done via Netsh.
Lastly, once the BranchCache
GPO settings have been configured, the next step is to configure Windows
Firewall to allow incoming HTTP and WS-Discovery traffic:
- Allow TCP HTTP - 80 Inbound (from all other BranchCache clients—at the branch office).
- Allow UDP WS-Discovery - 3702 Inbound (from all other BranchCache clients—at the branch office).
Services Dynamic Discovery, or WSD) is a technical specification for a
multicast discovery protocol that is used to locate services on a local
network. WSD, which is not proprietary to Microsoft, is used by
BranchCache to discover locally cached content. For example, BranchCache
clients will initiate multicast WSD Probe messages with the hashes of
the content probes to other BranchCache clients (also known as peers).
If these peers have the content, they will then reply with a unicast
To understand how this all works, here is the basic flow:
Client2 will first contact the content server FileServer1 for a document named File.doc.
FileServer1 will respond with list of hashes that make up the indices of the requested content.
Client2 will then send out a WSD Probe message to other clients in their local network.
If there is a match on another peer, it responds to the Probe message with a Probe-Match.
Client2 then will decide on where to get the content from (content server or other peers).
If content is retrieved from other peers, this is done via HTTP.
Testing Distributed Cache Mode
To test BranchCache in Distributed Cache mode, the following must be in place:
A Windows Server 2008 R2–based content server and content to put on that server.
Two different network segments with some sort of latency.
Two or more Windows 7 clients across continents from the content server.
after the previously mentioned requirements are in place and
BranchCache has been correctly configured for Distributed Cache mode,
BranchCache can be tested using the following steps:
On Client1, copy a file from the share on the content server to your desktop.
Next, on Client2, copy the same file from the share on the content server to your desktop.
These steps assume that BranchCache for network files is being tested.