MySQL 9.0 发行说明
此表提供了一种查找为此集群最近启动的备份的 ID 的方法。
backup_id
表包含一个列 id
,该列对应于使用 ndb_mgm 客户端 START BACKUP
命令获取的备份 ID。此表包含一行。
示例:假设在 NDB 管理客户端中发出以下 START BACKUP
命令序列,并且自集群首次启动以来未进行其他备份
ndb_mgm> START BACKUP
Waiting for completed, this may take several minutes
Node 5: Backup 1 started from node 50
Node 5: Backup 1 started from node 50 completed
StartGCP: 27894 StopGCP: 27897
#Records: 2057 #LogRecords: 0
Data: 51580 bytes Log: 0 bytes
ndb_mgm> START BACKUP 5
Waiting for completed, this may take several minutes
Node 5: Backup 5 started from node 50
Node 5: Backup 5 started from node 50 completed
StartGCP: 27905 StopGCP: 27908
#Records: 2057 #LogRecords: 0
Data: 51580 bytes Log: 0 bytes
ndb_mgm> START BACKUP
Waiting for completed, this may take several minutes
Node 5: Backup 6 started from node 50
Node 5: Backup 6 started from node 50 completed
StartGCP: 27912 StopGCP: 27915
#Records: 2057 #LogRecords: 0
Data: 51580 bytes Log: 0 bytes
ndb_mgm> START BACKUP 3
Connected to Management Server at: localhost:1186 (using cleartext)
Waiting for completed, this may take several minutes
Node 5: Backup 3 started from node 50
Node 5: Backup 3 started from node 50 completed
StartGCP: 28149 StopGCP: 28152
#Records: 2057 #LogRecords: 0
Data: 51580 bytes Log: 0 bytes
ndb_mgm>
在此之后,backup_id
表包含此处显示的单行,使用 mysql 客户端
mysql> USE ndbinfo;
Database changed
mysql> SELECT * FROM backup_id;
+------+
| id |
+------+
| 3 |
+------+
1 row in set (0.00 sec)
如果找不到备份,则该表包含一行,其中 0
作为 id
值。