Author: Vladimir Medina , SharePoint PFE, LATAM
If you, like me, are playing with SharePoint 2013 or if you have plans to migrate/deploy SharePoint 2013, you may have already heard about Distributed Cache (a.k.a. Velocity or AppFabric). In this post, I’d like to make you aware of some tips from the field that may help you avoid some serious issues in your production Farm.
First things first, see the following articles to learn about planning and managing Distributed Cache on SharePoint 2013:
As you know, real world scenarios are always different and more challenging than TechNet “ideal world” and some tips that we noted from Premier support cases are really valuable:
- When you run Configuration Wizard on SharePoint 2013 (a.k.a. psconfig), Distributed Cache service is enabled by default on that server. If you run the wizard on all SharePoint servers in the Farm, the service will be running on all those servers which is not the ideal configuration for your production environment. To avoid this problem, configure your servers via PowerShell instead of the wizard. After the first Farm server is configured, you can use connect-spconfigurationdatabase with –skipregisterasdistributedcachehost parameter.
- Plan to have a dedicated server or servers run only the Distributed Cache service. Avoid sharing that server(s) with any other service, even Central Administration, because Distributed Cache needs special considerations with respect to resources and maintenance activities.
- Recommended resources for dedicated servers are:
- 4 cores processor
- 24 GB RAM (8-16 GB dedicated for Distributed Cache)
- 1 Gbps network interface
- Physical and Virtual environments are supported, however on virtual environments dynamic memory is not supported
- Distributed Cache must be configured manually to use dedicated resources, so please run the following actions during the Farm Configuration process before starting the User Profile Service:
- Stop Distributed Cache service on all servers running it, wait on each one until the service stops
(the graceful parameter helps to move cache on that server to another available server)
- Then run cmdlet:
Update-SPDistributedCacheSize –CacheSizeinMB <size in MB>
Remember to use between 8 GB and 16 GB (16 GB used on real world scenarios with 24 GB RAM on server).
- Restart the service on all dedicated servers from Central Administration –> Services on the server
- Stop the service using the following cmdlet
on the server to be removed or on all dedicated servers (a.k.a. Cache Hosts)
TIP: If you need Distributed Cache to always be available then leave the service running on one server.
- Run the following cmdlet on all the servers except the one left running for availability:
If all servers have the service stopped then leave one without running this cmdlet, which will be your first server to restart.
- When your maintenance is over, go to Central Administration and start Distributed Cache service from Services on Server page, then wait until service is listed as “started.”
- Finally go to each Cache Host and run cmdlet:
- To verify everything is ok, run the following cmdlets from any Cache Host to see if all Cache Hosts are listed and service status is “UP”:
If you’d like to sleep well before and after your new SharePoint 2013 deployment/migration process, I encourage you to bookmark this article . I’m also really interested in your experience and comments, so please share your stories with us and help us learn and share more tips about SharePoint – all will be welcomed!