Set the node cache size based on site size (318976)



The information in this article applies to:

  • Microsoft Content Management Server 2001 SP1
  • Microsoft Content Management Server 2002
  • Microsoft Content Management Server 2002 SP1

This article was previously published under Q318976

SUMMARY

If the node cache setting in the Server Configuration Application (SCA) is not set high enough to hold all of the cacheable items in the CMS database, site performance can decrease and parts of your site may not be available during long running transactions such as background processing and site deployment. To make sure that site performance and availability are not affected by a node cache size that is too small, it is important to increase the node cache to reflect the number of objects that are to be cached.

MORE INFORMATION

The following SQL query calculates the number of items in the Content Management Server (CMS) database that must be accounted for when you configure the size of the node cache. To run this query, point your SQL Query Analyzer at your CMS database, and then paste and run the following SQL script in the SQL Query Analyzer window.

Npte Microsoft strongly recommends that you set your node cache to at least the number that is returned by this script. If constant authoring and updates occur on your site, increase the node cache size accordingly.
SELECT count(*) FROM node
WHERE (datediff(hour, archivedwhen, getdate()) < 1
  OR archivedwhen IS null)
  AND (deletedwhen is NULL)
  AND datediff(hour, expirydate, getdate()) < 1
  AND (datediff(hour, effectivedate, getdate()) > 1
    OR effectivedate IS null)
  AND (datediff(hour, approvedwhen, getdate()) > 1
    OR (type >= 65535 and approvedwhen is null))

				
If the returned value is higher than 35,000, you may not be able to load the whole site in memory. The available memory varies greatly. Factors, such as level of isolation for Microsoft Internet Information Services (IIS) and the other processes that IIS is running, can vary greatly, and all these factors influence your available memory. This dictates how high you can set your node cache. Therefore, it is a good idea to avoid increasing your node cache to anything higher than 35,000.

If the node cache is more than 35,000, Microsoft recommends that you run stress tests against your non-production servers to tune the node cache number. The stress test must be performed across the whole site and not only on several pages. If you perform a partial stress test, it does not create the appropriate environment for node cache tuning. If the return value from the previous script is between 2,000 and 35,000, the site will perform best on the number that is returned by the script.

If memory consumption is too high soon after you change the node cache, you must reduce the node cache number. If memory consumption is too high, more than 1 GB of virtual memory is being used on the instance that is running MCMS or performance is degraded. This problem is not likely to occur, but because there is no easy way to calculate the available memory, the node cache number may use all the available memory and therefore cause memory issues.

REFERENCES

For additional information, click the following article numbers to view the articles in the Microsoft Knowledge Base:

310819 Only cached objects are available during Site Deployment import

312060 PRB: Postings and images do not appear on live site after Site Deployment import


Modification Type:MajorLast Reviewed:11/3/2004
Keywords:kbinfo KB318976