MySQL 8.4 Release Notes
25.6.17.63 NDBinfo threads 表
threads
表提供了关于运行在 NDB
内核中的线程的信息。
threads
表包含以下列:
-
node_id
该线程在哪个节点上运行的 ID
-
thr_no
该节点上的线程 ID
-
thread_name
线程名称(线程类型)
-
thread_description
线程描述(线程类型)
以下是一个 2 个节点的示例集群,包括线程描述的样本输出:
mysql> SELECT * FROM threads;
+---------+--------+-------------+------------------------------------------------------------------+
| node_id | thr_no | thread_name | thread_description |
+---------+--------+-------------+------------------------------------------------------------------+
| 5 | 0 | main | main thread, schema and distribution handling |
| 5 | 1 | rep | rep thread, asynch replication and proxy block handling |
| 5 | 2 | ldm | ldm thread, handling a set of data partitions |
| 5 | 3 | recv | receive thread, performing receive and polling for new receives |
| 6 | 0 | main | main thread, schema and distribution handling |
| 6 | 1 | rep | rep thread, asynch replication and proxy block handling |
| 6 | 2 | ldm | ldm thread, handling a set of data partitions |
| 6 | 3 | recv | receive thread, performing receive and polling for new receives |
+---------+--------+-------------+------------------------------------------------------------------+
8 rows in set (0.01 sec)
还可以将 ThreadConfig
参数中的 main
或 rep
设置为 0,而将另一个设置为 1,在这种情况下,线程名称是 main_rep
,其描述是 主和副本线程,chema 分布代理块和异步复制处理
。您也可以将 main
和 rep
都设置为 0,在这种情况下,线程名称在该表中显示为 main_rep_recv
,其描述是 主、副本和接收线程,chema 分布代理块和异步复制处理和处理新接收和轮询
。