!150 修复dss僵死检测

Merge pull request !150 from 张翱/master
This commit is contained in:
opengauss_bot 2023-09-14 13:49:07 +00:00 committed by Gitee
commit 602d7bd6e1
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F

View File

@ -398,17 +398,15 @@ static void ProcessAbnormalInstance(CmResConfList *conf)
return;
}
write_runlog(LOG, "res(%s) inst(%u) has been abnormal (%d)s, >= timeout(%d)s, need restart.\n",
write_runlog(LOG, "res(%s) inst(%u) has been abnormal (%d)s, >= timeout(%d)s, need kill it.\n",
conf->resName, conf->cmInstanceId, duration, conf->checkInfo.abnormalTimeout);
RestartOneResInst(conf);
conf->checkInfo.startCount++;
conf->checkInfo.startTime = curTime;
if (conf->checkInfo.restartTimes != -1) {
write_runlog(LOG, "res(%s) inst(%u) has been restart (%d) times, restart more (%d) time will manually stop.\n",
conf->resName, conf->cmInstanceId, conf->checkInfo.startCount, conf->checkInfo.restartTimes);
if (CleanOneResInst(conf) == CM_SUCCESS) {
write_runlog(LOG, "res(%s) inst(%u) clean abnormal time.\n", conf->resName, conf->cmInstanceId);
} else {
conf->checkInfo.startCount++;
}
conf->checkInfo.startTime = curTime;
}
static inline bool NeedStopResInst(const char *resName, uint32 cmInstId)