当前位置:网站首页>[MySQL] methods for troubleshooting lock related problems
[MySQL] methods for troubleshooting lock related problems
2022-06-13 07:37:00 【Fish is not fish】
Preface
Believe that whatever you do DBA Or development , In fact, no one wants to encounter the lock , Because the lock is a
Double-edged sword , If used well, it can protect the concurrent access competition to resources , But in bad words , It's easy to cause
Online problem , For example, deadlock. , Lock wait , Business waiting , Business is not available , The database performance drops dramatically .
MySQL Lock correlation table
I'm sure you all know that ,MySQL There are many kinds of locks , Read lock, write lock, metadata lock, etc .
To get to the point, how do we check locks , Generally, the following tables are used :5.7 edition Information_schema.innodb_locks The table shows the current waiting locks Information_schema.innodb_trx The table can query the currently uncommitted transactions
8.0 edition , Abandoned the previous innodb_locks surface Added the following tables stay performance_schema Here are a few tables : data_lock_waits. Displays the currently waiting locks data_locks. Display all current locks metadata_locks Display the details of the current metadata lock
MySQL Lock monitoring related
Innodb_row_lock_current_waits
: Number of locks currently waiting Innodb_row_lock_time
: It takes a total of time to wait for the lock from the start of the system to the present Innodb_row_lock_time_avg
: The average time between system startup and lock waiting Innodb_row_lock_time_max
: The longest time between system startup and lock waiting Innodb_row_lock_waits
: Total number of lock waits since system startup
边栏推荐
- P1434 [SHOI2002] 滑雪 (记忆化搜索
- Redis learning journey -- getting to know redis for the first time
- Redis Cluster - the underlying principle of slot assignment
- socket编程2:IO复用(select && poll && epoll)
- 25 domestic and foreign literature databases
- Learning notes of balanced binary tree -- one two pandas
- Table access among Oracle database users
- Compilation and development process of Quanzhi v3s environment
- Issues related to C # delegation and events
- MySQL table cache most detailed notes
猜你喜欢
Table access among Oracle database users
Redis learning journey -- getting to know redis for the first time
Hashtable source code analysis
比较DFS和BFS的优点和缺点及名称词汇
RT thread simulator lvgl control: button button event
MySQL Gtid_ Executed and gtid_ Purged modification time
Compare advantages and disadvantages of DFS and BFS and name vocabulary
Some optimization for seckill project
Redis cluster parsing docker building redis cluster
Redis learning journey sentinel mode
随机推荐
Sorting of numbers and strings
Oracle problem: the data in the field is separated by commas. Take the data on both sides of the comma
Issues related to C # delegation and events
MySQL does not recommend setting the column default value to null. Why on earth is this
c#高級編程-特性篇
Learning notes of balanced binary tree -- one two pandas
redis-4. Redis' message subscription, pipeline, transaction, modules, bloom filter, and cache LRU
Redis learning journey sentinel mode
Considerations for using redis transactions
Redis learning journey --redis Conf details
Redis learning journey - persistence
Mui mixed development - when updating the download app, the system status bar displays the download progress
Redis learning journey - transaction
Redis underlying data structure - underlying principle of hash table
redis-0. Introduction to redis and NiO principle (random talk)
How app inventor accesses resource files in assets directory
An example of CSRF attack defense in web application scenarios
The management practice of leading enterprises has proved that what is the core of sustainable development of enterprises?
2021-10-08
论文笔记: 多标签学习 BP-MLL