Open ZSH9053 opened 3 years ago
Dec 17 03:51:06 jy-crm-pgsql-prod-db02 expgsql(pgsql)[224191]: ERROR: Can't obtain distributed lock on promote. Dec 17 03:51:06 jy-crm-pgsql-prod-db02 expgsql(pgsql)[224191]: ERROR: Can't obtain distributed lock on promote. Dec 17 03:51:06 jy-crm-pgsql-prod-db02 expgsql(pgsql)[224798]: INFO: Stopping PostgreSQL on demote. Dec 17 03:51:06 jy-crm-pgsql-prod-db02 expgsql(pgsql)[224798]: INFO: Stopping PostgreSQL on demote. Dec 17 03:51:06 jy-crm-pgsql-prod-db02 expgsql(pgsql)[224798]: INFO: stop_escalate(or stop_escalate_in_slave) time is adjusted to 50 based on the configured timeout. Dec 17 03:51:06 jy-crm-pgsql-prod-db02 expgsql(pgsql)[224798]: INFO: stop_escalate(or stop_escalate_in_slave) time is adjusted to 50 based on the configured timeout. Dec 17 03:51:06 jy-crm-pgsql-prod-db02 expgsql(pgsql)[224798]: INFO: server shutting down Dec 17 03:51:06 jy-crm-pgsql-prod-db02 expgsql(pgsql)[224798]: INFO: server shutting down Dec 17 03:51:11 jy-crm-pgsql-prod-db02 expgsql(pgsql)[224798]: INFO: PostgreSQL is down Dec 17 03:51:11 jy-crm-pgsql-prod-db02 expgsql(pgsql)[224798]: INFO: PostgreSQL is down Dec 17 03:51:11 jy-crm-pgsql-prod-db02 expgsql(pgsql)[224798]: INFO: Removing /var/lib/pgsql/tmp/PGSQL.lock. Dec 17 03:51:11 jy-crm-pgsql-prod-db02 expgsql(pgsql)[224798]: INFO: Removing /var/lib/pgsql/tmp/PGSQL.lock. Dec 17 03:51:11 jy-crm-pgsql-prod-db02 expgsql(pgsql)[224798]: INFO: Changing pgsql-status on jy-crm-pgsql-prod-db02 : HS:sync->STOP. Dec 17 03:51:11 jy-crm-pgsql-prod-db02 expgsql(pgsql)[224798]: INFO: Changing pgsql-status on jy-crm-pgsql-prod-db02 : HS:sync->STOP. Dec 17 03:51:12 jy-crm-pgsql-prod-db02 expgsql(pgsql)[225357]: INFO: PostgreSQL is already stopped. Dec 17 03:51:12 jy-crm-pgsql-prod-db02 expgsql(pgsql)[225357]: INFO: PostgreSQL is already stopped.
看下主库是否正常。主库正常时备库不应该去抢锁,出现这种情况可能是备库以为主库故障了, 看下备库和主库间的corosync的通讯是否出现异常。
今天早上看到PG备库挂了,cls_status 看到的是 备库:Can't obtain distributed lock on promote 这个有啥解决办法吗?仲裁节点正常。