Question :
I’m running SQL2019 CU4 Linux and seeing a high number of PWAIT_EXTENSIBILITY_CLEANUP_TASK. Can anyone share their insight on what this wait type means and how we can reduce it?
Select * from sys.dm_os_wait_stats
WHERE
wait_time_ms<>0
and wait_type='PWAIT_EXTENSIBILITY_CLEANUP_TASK'
order by signal_wait_time_ms desc
Answer :
Looks like a background task; those usually run all the time, so they generate high waits but they’re benign and there’s not really much you can do about them (and you’ll find this wait is filtered out of the popular diagnostic scripts out there).
Questions to ask yourself, when investigating a wait you can’t get much information on, there’s usually a reason (it’s obscure because it’s a nothin-burger).
- Do you see an actual problem associated with this wait?
- Do you see any actual sessions waiting on this (check
sys.dm_exec_session_stats
, but I doubt you’ll find anything, because these types of waits aren’t waits users wait on).
You’ll always have a highest wait even if your system is completely idle, it doesn’t mean the highest wait is a problem.
This post might be worth a read, but the TL;DR is that you’re always going to have waits and the highest wait isn’t necessarily a problem you need to solve. The analogy I use when teaching is that you’re always going to have a worst employee, but you can’t constantly fire your worst employee for very long.
FWIW I also see this as one of my top waits, but like SP_SERVER_DIAGNOSTICS_SLEEP
, XE_TIMER_EVENT
, and SOS_WORK_DISPATCHER
, I’m not panicking. When I see evidence that there is a performance problem and I can tie it to this wait (or resources that are congruent), I’ll dig.