LOGPOOL_REPLACEMENTSET

(Republishing, or using this info in a commercial product/website, is prohibited without permission. All other uses are permitted. If in doubt, please ask.)

(Back to main page…)

Description:

This wait type is when a thread is waiting for an operation to do with the log pool. This is an in-memory cache of recently flushed log blocks, to help avoid log readers having to do physical reads of the log file (e.g. for sending log blocks to asynchronous availability group replicas).

(Books Online description: N/A)

Questions/comments on this wait type? Click here to send Paul an email, especially if you have any information to add to this topic.

Added in SQL Server version:

2012

Removed in SQL Server version:

N/A

Extended Events wait_type value:

The map_key value in sys.dm_xe_map_values is 771 in 2012 and 789 in 2014 RTM. After 2014 RTM, you must check the DMV to get the latest value as some map_key values have changed in later builds.

Other information:

I have heard anecdotal evidence of this wait type being a contention point in situations where there are log readers (e.g. replication) and a quickly growing log, for instance, from a large index rebuild in the full recovery mode.

Known occurrences in SQL Server (list number matches call stack list):

  1. Waiting for a log block to be pushed into the log pool (in this case, while expanding the log cache for a database)

Abbreviated call stacks (list number matches known occurrences list):

  1. SOS_Task::PostWait+9e
    EventInternal<SuspendQueueSLock>::Wait+2ca
    SOS_RWLock::GetLongWait+10b
    LogPoolSharedCacheBufferMgr::WaitOnReplacementSet+14e
    LogPoolSharedCacheBufferMgr::Push+195
    SQLServerLogMgr::FormatLC+110
    SQLServerLogMgr::FlushLC+50b
    SQLServerLogMgr::LogWriter+d62
    SOS_Task::Param::Execute+21e
    SOS_Scheduler::RunTask+ab