How to capture deadlock information

Master_BlasterAsked:
Who is Participating?
 
Jeremy_DConnect With a Mentor Commented:
They are available in 7.0 SP2 installation. Not sure about previous 7.0 SPs, but I seem to recall that they didn't add new events until SP3...
0
 
sachiekCommented:
Which version of SQL svr are u using? 6.5x or 7.x or 2k?


Sachi
0
 
Master_BlasterAuthor Commented:
SQL Server v.7.0
0
Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

 
ZhongYuCommented:
Deadlock information is written in SQL error log. It does not happen often.

 
0
 
Guy Hengel [angelIII / a3]Billing EngineerCommented:
Deadlocks should be avoided as much as possible...
If you run already into deadlocks, you must review your code!

As ZhongYu indicates, deadlocks are written in the SQL error log. Now to debug deadlocks, you need to check the locks on the objects, and locate the code that issues these locks.

Cheers
0
 
Jeremy_DCommented:
Fire up SQL Profiler. Start a new trace. From the 'Events' tab, select 'Lock: Deadlock' and 'Lock: Deadlock chain' (under the heading 'Locks') and add them to the selected events. Let it run for a while...
0
 
Guy Hengel [angelIII / a3]Billing EngineerCommented:
Are the Trace Deadlocks not avaible since SQL 2000?
not sure...
0
 
nigelrivettCommented:
Set on the trace flags.
I think it's 1204, 1205 - you shold be able to find it in bol, this will give info about the instructions involved in the deadlocks.
0
 
CleanupPingCommented:
Master_Blaster:
This old question needs to be finalized -- accept an answer, split points, or get a refund.  For information on your options, please click here-> http:/help/closing.jsp#1 
EXPERTS:
Post your closing recommendations!  No comment means you don't care.
0
 
SQLMasterCommented:
No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:
Accept Jeremy_D's comment as answer
Please leave any comments here within the next seven days.

PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!

Dheeraj Jain
EE Cleanup Volunteer
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.