Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 kill process

Author  Topic 

kbk
Starting Member

34 Posts

Posted - 2009-01-30 : 08:10:33
If a process utilizes a lot of cpu usage,what is the best way 2 resolve it?is killing the process recommended??what if it is a suspended or runnable process?

bk

RickD
Slow But Sure Yak Herding Master

3608 Posts

Posted - 2009-01-30 : 08:50:52
Find out what is causing it and re-write the process.
Go to Top of Page

tosscrosby
Aged Yak Warrior

676 Posts

Posted - 2009-01-30 : 09:00:40
Don't kill anything unless you know what the process is doing. And killing the process, depending on what it's doing, can cause a rollback, which is also going to consume some resources. Start a trace and takes Rick's advice. If you resolve the issue, you'll look like a star....well maybe not but you'll have something to show the boss when it's review time.

Terry

-- Procrastinate now!
Go to Top of Page

kbk
Starting Member

34 Posts

Posted - 2009-01-30 : 13:02:29
Im a beginner in sql dba.i find many processes that are in suspended or runnable mode to be utilizing cpu.how do we find the cause of it??is it within the dba's scope to rewrite it?

bk
Go to Top of Page

sodeep
Master Smack Fu Yak Hacker

7174 Posts

Posted - 2009-01-30 : 13:06:43
How do you know they are utilizing high CPU? Run Standard Reports that comes with SQL Server for CPU utilization
Go to Top of Page

kbk
Starting Member

34 Posts

Posted - 2009-01-30 : 13:46:25
From activity monitor in sql server 2005 as well as using this query.It gives the process id as well as the text/procedure which utilizes max cpu time

SELECT sqltext.TEXT,
req.session_id,
req.status,
req.command,
req.cpu_time,
req.total_elapsed_time
FROM sys.dm_exec_requests req
CROSS APPLY sys.dm_exec_sql_text(sql_handle) AS sqltext


bk
Go to Top of Page

sodeep
Master Smack Fu Yak Hacker

7174 Posts

Posted - 2009-01-30 : 14:06:18
Did you use Standard reports as I said? You need to have proper indexes and stats updated?
Go to Top of Page

kbk
Starting Member

34 Posts

Posted - 2009-01-30 : 14:15:54
No reporting services isnt installed.

bk
Go to Top of Page

sodeep
Master Smack Fu Yak Hacker

7174 Posts

Posted - 2009-01-30 : 14:21:44
I am not asking for Reporting Services? Right click you server - Reports -Standard reports.
Go to Top of Page

kbk
Starting Member

34 Posts

Posted - 2009-01-30 : 14:33:15
Oh Ok...thank you very much.i wasnt aware of the option as im new to this field.but this again gives the same info right?how do we resolve the cpu utilization issue once we get the queries(from the report) that utilize CPU time

bk
Go to Top of Page

sodeep
Master Smack Fu Yak Hacker

7174 Posts

Posted - 2009-01-30 : 14:39:41
See Execution plan and Tune with indexes if they need. You can get some help from Database Tuning Advisor.
Go to Top of Page
   

- Advertisement -