Known as one of the most popular open source database, MySQL is widely used in various scenarios, ApsaraDB RDS for MySQL of Alibaba Cloud provided critical relief for companies, especially small and medium-sized enterprises affected by novel coronavirus (COVID-19).
The thread has called mysql_lock_tables() and the thread state has not been updated since. This is a very general state that can occur for many reasons. For example, the thread is going to request or is waiting for an internal or external system lock for the table. This can occur when InnoDB waits for a table-level lock during execution of LOCK TABLES. If this state is being caused by requests for external locks and you are not using multiple mysqld servers
that are accessing the same MyISAM tables, you can disable external system locks with the --skip-external-locking option. However, external locking is
disabled by default, so it is likely that this option will have no effect. For SHOW PROFILE, this state means the thread is requesting the lock (not waiting
for it).
System Lock
This thread is called by Mysql_lock_tables (). This state can be caused by a number of reasons.
For example, a thread wants to request or is waiting for the internal or external system lock of a table;
It may also be innodb in the execution of lock tables, such as table-level lock;
It is also possible to request an internal lock, such as accessing the same myism table without using multiple MYSQLD services;
In this case, you can disable the internal system locks with the--skip-external-locking option. However, if the internal lock is disabled by default, that option will be useless.
If you encounter this state at show profile, it means that the thread is requesting a lock (not a wait).
Source: https://dev.mysql.com/doc/refman/5.7/en/general-thread-states.html
The MySQL thread is in the system lock state