sys.dm_os_schedulers has a column call current_worker_count .
May I know what's the situation that this current_worker_count will be reset .?
as I know active_workers_count < this number will be changed dynamically by SOS . thanks
sys.dm_os_schedulers has a column call current_worker_count .
May I know what's the situation that this current_worker_count will be reset .?
as I know active_workers_count < this number will be changed dynamically by SOS . thanks
Hi @sakuraime,
The Scheduler is responsible for creating and destroying Workers according to requirements. Workers use Scheduler directly. Each Worker can only be associated with one Scheduler. Workers cannot be transferred from one Scheduler to another.
The unit of work processed by the Worker can be a Request or a Task. For example, batch processing Request may be decomposed into multiple Tasks. When the Scheduler receives a new Request or Task request, if there is no idle Worker (Idle Worker) currently, it will start to create a new Worker according to the configuration, and the Request or Task will be bound to the Worker.
I find a blog explain this, but the blog is in Chinese, please refer to SQL Server scheduler.
If the response is helpful, please click "Accept Answer" and upvote it, as this could help other community members looking for similar queries.
May I know what's the situation that this current_worker_count will be reset .?
Maybe you could explain your actual problem instead? Do you see this column be "reset"? What other problems are you experiencing on the system?
so the max of the worker thread setting is controlling the current_worker_thread or active_worker_thread ?
Hi @sakuraime,
From my understanding, the value of the current_worker_thread column is related to the request and task. When the Scheduler receives a new Request or Task request, if there is no idle Worker currently, it will start to create a new Worker. And if the worker has been idle for at least 15 minutes or more, or when SQL Server detects memory pressure, the idle worker may be destroyed. For this two situation, the value of current_worker_count will be change.
I do not ever suggest changing the max worker threads on a system (since SQL 2000). The default value is good for 99.99% of installations. This is not something you normally need to worry about.
12 people are following this question.