问题描述
我们在单独的服务器(装有Ubuntu 18.04 LTS的VM)上有一个应用程序管道和Postgres-12(TimescaleDB,通过Patroni管理)。
我们正面临数据库的问题,它突然卡在恢复模式中,而且我们无法从psql客户端访问它并选择挂起的查询。
一个小时或一个小时后,一切恢复正常(由于我当前的管道终止),并且能够对数据库服务器运行查询。
@import '~@angular/material/prebuilt-themes/indigo-pink.css';
复制服务器错误详细信息:
2020-11-03 18:35:08.612 IST [9773] [unkNown]@[unkNown] LOG: connection received: host=x.x.x.x port=58780
2020-11-03 18:35:08.612 IST [9773] FATAL: the database system is in recovery mode
2020-11-03 18:35:08.596 IST [18276] LOG: Could not send data to client: broken pipe
管道错误详细信息:
2020-11-03 18:34:55 IST [18316]: [85649-1] user=postgres,db=postgres,app=[unkNown],client=x.x.x.x LOG: duration: 10.228 ms statement: SELECT * FROM pg_stat_bgwriter;
WARNING: terminating connection because of crash of another server process
DETAIL: The postmaster has commanded this server process to roll back the current transaction and exit,because another server process exited abnormally and possibly corrupted shared memory.
HINT: In a moment you should be able to reconnect to the database and repeat your command.
2020-11-03 18:35:08 IST [18322]: [2-1] user=,db=,app=,client= FATAL: Could not receive data from WAL stream: SSL SYSCALL error: EOF detected
2020-11-03 18:35:08 IST [20500]: [1-1] user=,client= FATAL: Could not connect to the primary server: FATAL: the database system is in recovery mode
FATAL: the database system is in recovery mode
对此问题有何建议?
解决方法
您正在运行什么版本的TimescaleDB?尤其是,如果您尝试查询只读副本,则1.7.x会出现一些问题。我们建议升级到1.7.4。
(否则,没有太多信息可以建议可能发生的事情。)