| Lesson 8 || Monitoring with dbcc, continued |
|Objective || Use dbcc buffer to monitor the Data Cache |
Use dbcc buffer to monitor Data Cache
dbcc buffer command is used to look at the SQL Servers data cache. You can see all of the cache, including the cache for a specific database, for a specific object, or a given number of pages.
You also have the capability of controlling the number of pages returned.
This dbcc command is not documented by Microsoft and should use your own judgement when using the command.
The syntax of the
dbcc buffer command is as follows:
dbcc buffer [(dbname|db_id [,object_name|objectid [,number of pages [ ,display option]]] )]
Buffer Page Header
returns information, it returns the most recently used (MRU)
page first; unless the number of pages is less than 0, then it returns the
least recently used (LRU)
page first. The display option can be 0 (default), 1, 2, or 3. The following SlideShow illustrates the output of the
Least recently used (LRU): The in memory data page that has gone the longest time without being accessed.
In the next lesson, you will learn about three more methods for using dbcc to monitor SQL Server performance.
Most recently used (MRU):
The in memory data page that was the last data page to be accessed.