如何解决死锁问题? [英] how to solve deadlock problem?

查看:30
本文介绍了如何解决死锁问题?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我读过这个死锁问题 当数据库表开始累积数千行并且许多用户开始同时处理同一个表时,表上的 SELECT 查询开始产生锁争用和事务死锁.

i have read this dead lock problem When database tables start accumulating thousands of rows and many users start working on the same table concurrently, SELECT queries on the tables start producing lock contentions and transaction deadlocks.

这个死锁问题是否与 TransactNo updlock 有关?如果你知道这个问题,请告诉我.提前致谢.

Is this deadlock problem related with TransactNo updlock? If you know this problem, let me know pls. Thanks in advance.

推荐答案

发生死锁的原因有很多,有时解决死锁问题与其说是科学,不如说是一门艺术.

Deadlocks can occur for many reasons and sometimes troubleshooting deadlocks can be more of an art than a science.

在普通 SQL Profiler 之外,我用来查找和消除死锁的是一个轻量级工具,它可以在死锁发生时提供图形化的描述.当您看到死锁时,您可以深入了解并获取有价值的信息.死锁检测器 -- http://www.sqlsolutions.com/products/sql-deadlock-检测器

What I use to find and get rid of deadlocks, outside of plain SQL Profiler, is a lightweight tool that gives a graphical depiction of deadlocks as they occur. When you see a deadlock, you can drill down and get valuable information. Deadlock Detector -- http://www.sqlsolutions.com/products/sql-deadlock-detector

这是一个简单的工具,但对我来说,它完全可以完成它应该做的事情.有一件事:我第一次使用它时,我不得不等待 15 分钟,以便该工具收集足够的指标以开始显示死锁.

It's a simple tool, but for me, it does exactly what it is supposed to do. One thing: the first time I used it, I had to wait 15 minutes for the tool to gather enough metrics to start showing deadlocks.

这篇关于如何解决死锁问题?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆