Labels

Sunday, 1 May 2016

SQL DBA : My CPU utilization is 100% then what you will do ?


If CPU Utilization is 100%, then identify

1) If SQL Server is consuming CPU or some other process.

2) If SQL Server is not consuming then assign the incident to Windows team / Wintel Team to investigate.

3) If SQL Server is consuming 100% CPU then

Monitor % Processor Time (_Total) to confirm the utilization of all processors is high or less.
  
Investigating High Processor Utilization:

High processor utilization is to break it down into Processor(_Total)\% Privileged Time and Processor(_Total)\% User Time

System\Processor Queue Length counter gives an indication of how many threads are waiting for execution.

If multiple instances are present in the server, check which instance is busy with Processor in Task Manager and identify instance using PID in Configuration Manager.

4) Verify the session count to SQL Server instance.

select count(*) from sys.dm_exec_sessions

Validate with the benchmark value and find the load on the system.

5) Verify if any blocking's are there in SQL Server instance.

6) If blocking's are not identified, then run Profiler (with approval) to understand the load on the system.

7) Identify long running queries and inform application team about the longest and oldest transactions which are taking maximum CPU utilization.

select * from sys.dm_exec_requests order by cpu desc

Note: In our environment , We faced this issue at the time of  Antivirus is scanning the .mdf and .ldf files so to fix this we have excluded the database files from antivirus scan.

No comments:

Post a Comment