java - 数据库用户表的一些用户莫名其妙出现了死锁
巴扎黑
巴扎黑 2017-04-17 17:37:06
0
2
417

mysql 数据库,最近没有代码更新,数据库方面也没有变动

有用户反映登出之后再登录就没反应了,查数据库发现是该用户的数据出现死锁,并且有蔓延的趋势

能排除是数据库遭到攻击吗?

遇到类似情况的各路大仙给个建议

跪谢 orz

巴扎黑
巴扎黑

reply all(2)
黄舟

Frequent data operations will cause
It is possible to access the aggregate index and the non-aggregate index successively, thus blocking each other and forming a deadlock.
The deadlock may be locked on different resources, or it may be locked on the same resource. It can Understand the principle of deadlock and the principle of execution engine locking.
Generally, operating resources in the same order, not using a higher level transaction isolation level or using optimistic locking is the solution. How to do it depends on how you write your query and how you build the index.

巴扎黑

The cause of deadlock is resource competition. Waiting for each other leads to deadlock.

The attack is not just a deadlock problem. Check the cause from the program.

It should just be a deadlock problem. The reason is: an increase in concurrent operations, an increase in the number of users, and functional defects. For example, the same resources, such as the same data in the same table, will be used by multiple users at the same time, and the functional design is repeated. Internal processing has its own sequence.

It is recommended to ask a DBA to help you take a look.

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template