From a57f876d4d1adb43f076fb25da76e4f231f51398 Mon Sep 17 00:00:00 2001 From: liyang0608 <264327807@qq.com> Date: Mon, 16 Nov 2020 09:31:53 +0800 Subject: [PATCH] fix bugs --- ...66\346\200\201\345\274\202\345\270\270.md" | 35 ------------------- content/zh/menu/index.md | 1 - 2 files changed, 36 deletions(-) delete mode 100644 "content/zh/docs/Developerguide/\346\225\260\346\215\256\350\212\202\347\202\271\351\207\215\345\273\272\350\277\207\347\250\213\344\270\255\351\207\215\345\220\257\351\233\206\347\276\244-\345\257\274\350\207\264\351\233\206\347\276\244\345\220\257\345\212\250\347\212\266\346\200\201\345\274\202\345\270\270.md" diff --git "a/content/zh/docs/Developerguide/\346\225\260\346\215\256\350\212\202\347\202\271\351\207\215\345\273\272\350\277\207\347\250\213\344\270\255\351\207\215\345\220\257\351\233\206\347\276\244-\345\257\274\350\207\264\351\233\206\347\276\244\345\220\257\345\212\250\347\212\266\346\200\201\345\274\202\345\270\270.md" "b/content/zh/docs/Developerguide/\346\225\260\346\215\256\350\212\202\347\202\271\351\207\215\345\273\272\350\277\207\347\250\213\344\270\255\351\207\215\345\220\257\351\233\206\347\276\244-\345\257\274\350\207\264\351\233\206\347\276\244\345\220\257\345\212\250\347\212\266\346\200\201\345\274\202\345\270\270.md" deleted file mode 100644 index 502f0e4da..000000000 --- "a/content/zh/docs/Developerguide/\346\225\260\346\215\256\350\212\202\347\202\271\351\207\215\345\273\272\350\277\207\347\250\213\344\270\255\351\207\215\345\220\257\351\233\206\347\276\244-\345\257\274\350\207\264\351\233\206\347\276\244\345\220\257\345\212\250\347\212\266\346\200\201\345\274\202\345\270\270.md" +++ /dev/null @@ -1,35 +0,0 @@ -# 数据节点重建过程中重启集群,导致集群启动状态异常 - -## 问题现象 - -在一主多备集群或主备从集群部署模式下,对某一数据节点重建,在此过程中,重启集群,该数据节点状态为Pending Starting,其余数据节点状态为Pending Need Repair,无法仲裁出主备,状态为Pending Starting的数据节点产生大量无法接受业务连接的日志。 - -``` -redo minRecoveryPoint at 2/321C31C0; backupStartPoint at 1/C13075B0; backupEndRequired FALSE LOG: redo starts at 1/C5F9D820 LOG: invalid record length at 2/2170F700: wanted 32, got 0 FATAL: the database system is starting up FATAL: the database system is starting up FATAL: the database system is starting up ... -``` - -## 原因分析 - -1. 集群启动过程中,所有数据节点状态是Pending Starting。首先对已有xlog进行REDO,日志分析发现问题数据节点已经REDO到了后一条xlog record,依然没有达到ControlFile里的最小恢复点MinRecovery Point。 -2. 问题数据节点在该场景下,无法在REDO过程中通过CheckConsistency检查,无法发信号给PostMaster主线程,进行PM状态机迁移。 -3. 集群以归档恢复模式启动,由于状态机无法正常迁移,因此数据节点无法接受连接,CM Agent无法将数据节点的状态设置成Pending Need Repair。 -4. 在该问题场景下,CM Server无法仲裁出数据节点的主备,导致数据节点的REDO线程一直循环, 无法接收外部业务请求,报错信息显示如下。 - - ``` - FATAL : the database system is starting up - ``` - - -## 处理办法 - -1. 终止处于Pending Starting状态的数据节点进程,即剔除数据节点。 -2. 等待其他处于Pending Need Repair状态的数据节点仲裁出主备,恢复到Primary Normal或Standby Normal状态。 -3. 执行如下命令对有问题数据节点进行全量重建,待其重建成功后则问题修复。 - - ``` - cm_ctl build -n NODEID -D DATADIR -b full - ``` - - NODEID是节点ID,DATADIR是待重建数据节点的数据目录。 - - diff --git a/content/zh/menu/index.md b/content/zh/menu/index.md index 768f6e3f0..691783acb 100644 --- a/content/zh/menu/index.md +++ b/content/zh/menu/index.md @@ -1216,7 +1216,6 @@ headless: true - [出现“Error:No space left on device”提示]({{< relref "./docs/Developerguide/出现-Error-No-space-left-on-device-提示.md" >}}) - [在XFS文件系统中,使用du命令查询数据文件大小大于文件实际大小]({{< relref "./docs/Developerguide/在XFS文件系统中-使用du命令查询数据文件大小大于文件实际大小.md" >}}) - [在XFS文件系统中,出现文件损坏]({{< relref "./docs/Developerguide/在XFS文件系统中-出现文件损坏.md" >}}) - - [数据节点重建过程中重启集群,导致集群启动状态异常]({{< relref "./docs/Developerguide/数据节点重建过程中重启集群-导致集群启动状态异常.md" >}}) - [switchover操作时,主机降备卡住]({{< relref "./docs/Developerguide/switchover操作时-主机降备卡住.md" >}}) - [磁盘空间达到阈值,数据库只读]({{< relref "./docs/Developerguide/磁盘空间达到阈值-数据库只读.md" >}}) - [分析查询语句长时间运行的问题]({{< relref "./docs/Developerguide/分析查询语句长时间运行的问题.md" >}}) -- Gitee