How to Track Deadlock Problem

  • I am getting deadlock errors occassionally when users attempt to use a third party application. I want to setup a trace to try and identify what is causing the problem but am not sure what components to select for my trace. Can anyone give me some advice on this please?

    Thanks

  • in profiler you should add the deadlock graph and lock: deadlock chain events in the Locks object. This will produce a graph that will show what processes locked up and the object they deadlocked on.

  • Thanks for the info, I'll give it a go and see what it reports!

  • Other option is to enable traceflag 1204 or 1222. SQL will write the deadlock graph into the error log.

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • Here is the bible on deadlock troubleshooting: http://blogs.msdn.com/bartd/archive/2006/09/09/Deadlock-Troubleshooting_2C00_-Part-1.aspx

    Best,
    Kevin G. Boles
    SQL Server Consultant
    SQL MVP 2007-2012
    TheSQLGuru on googles mail service

  • Interesting article, thanks for the link

Viewing 6 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic. Login to reply