In last week of August, I observed that sys.dm_os_memory_clerks was showing duplicate entries for all the memory clerks. For example, if I run the following code in SQL Server 2008 RTM:
select * from sys.dm_os_memory_clerks
where type = 'MEMORYCLERK_SQLBUFFERPOOL'
I get the following output:
You can observe that there are 2 entries for the BUFFER POOL memory clerk. Initially, I thought that it is for different memory nodes and I was wondering that it could have something to do with NUMA. But if you observer that memory_node_id columns shows 0 for both the entries, leaving me completely baffled, more so when the memory_clerk_address for both the records are different.
I interacted with my MVP colleagues Maciej Pilecki & Adam Mechanic (SQL MVPs) tried to figure out the issue. Adam pointed out that this could be for DAC (Dedicated Administrator Connection) – but then the memory node id should be different. Finally Umachandar Jayachandran, Robert Dorr & Bob Ward from Microsoft intervened and we figured out that this is an issue and not well known by many. So here is the story:
The other entry (what we see as duplicate) is actually for DAC and Adam was right. SQL Server 2008 RTM shows the physical memory node (0) for DAC entry which is incorrect. This issue was fixed in R2. If you run the same DMV in SQL Server 2008 R2, you will get the correct output as follows:
Memory Node ID 64 is logical and belongs to DAC.
Thanks to all the MVPs and folks from Microsoft helping me resolve this.