“Resource Governor in SQL Server Performance Tuning”

 Resource Governor is a feature that can manage SQL Server Workload and System Resource Consumption.

There are different nature of workloads like heavy, light workloads. SQL Server processes various types of workloads like SQL queries, transactions.

If heavy workload takes all the memory from CPU and because of that other operations to get affected then it is a very bad thing.

In order to process these workloads, the appropriate CPU power and RAM memory needs to be allocated. Resource governor is used for how much memory and CPU should be allocated to the resources.

Steps for the Resource Governor as follows -

  • Firstly, go to the Management →Click on the Resource Governor →Create a New Resource Pool.
Image for post
CREATE A NEW RESOURCE POOL
  • Create a User-Defined Function →This function is created in the master database →It will map the incoming SQL request to the accurate workload.
Image for post
WRITE A FUNCTION
  • If there are different workloads running on SQL Server and each of the workloads needs different resources or when workloads are competing for resources with each other and affecting the performance of the whole server resource governor is an important task.
  • For example, the resource governor helps to goes and create pulls and say that one process gives 80% and the other 20%.
Image for post
SPECIFY A WORKLOAD, GROUPS
  • Workload groups are created under the MyRsourcePool.
Image for post
WORKLOAD GROUPS ARE CREATED
  • To see how memory allocated to the resources go to the performance monitor →For this run the command PerfMon.
Image for post
RUN THE PERFMON COMMAND
  • In this first, Remove all counters →Then Right-click on white space →Click on Add counters.
Image for post
ADD COUNTER
  • After that add Resource pool stat counter →Add default, internal and MyResourcePool →Click on ok.
  • For example, the resource governor helps to goes and create pulls and say that one process gives 80% and the other 20%.
Image for post
ADDED COUNTERS
Image for post
RESOURCE POOL STATS
  • Finally, it will show the performance.
Image for post

Comments

Popular posts from this blog

Maxpooling vs minpooling vs average pooling

Understand the Softmax Function in Minutes

Percentiles, Deciles, and Quartiles