目前我只有两张桌子——一张可以正常工作的小桌子,另一张可能很大。当我尝试在 pgAdmin 中找出行数时,出现以下错误:
The application has lost the database connection:
⁃ If the connection was idle it may have been forcibly disconnected.
⁃ The application server or database server may have been restarted.
⁃ The user session may have timed out.
Do you want to continue and establish a new session?
我还检查了 Postgres 服务器日志:
2020-03-30 03:06:06.764 MSK [37356] LOG: server process (PID 30712) was terminated by signal 9: Killed: 9
2020-03-30 03:06:06.764 MSK [37356] DETAIL: Failed process was running: SELECT COUNT(*)::text FROM ios.task_info;
2020-03-30 03:06:06.764 MSK [37356] LOG: terminating any other active server processes
2020-03-30 03:06:06.765 MSK [30810] WARNING: terminating connection because of crash of another server process
2020-03-30 03:06:06.765 MSK [30810] 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.
2020-03-30 03:06:06.765 MSK [30810] HINT: In a moment you should be able to reconnect to the database and repeat your command.
2020-03-30 03:06:06.765 MSK [30709] WARNING: terminating connection because of crash of another server process
2020-03-30 03:06:06.765 MSK [30709] 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.
2020-03-30 03:06:06.765 MSK [30709] HINT: In a moment you should be able to reconnect to the database and repeat your command.
2020-03-30 03:06:06.767 MSK [37356] LOG: all server processes terminated; reinitializing
2020-03-30 03:06:06.776 MSK [30816] LOG: database system was interrupted; last known up at 2020-03-30 02:51:14 MSK
2020-03-30 03:06:06.818 MSK [30817] FATAL: the database system is in recovery mode
2020-03-30 03:06:06.853 MSK [30816] LOG: database system was not properly shut down; automatic recovery in progress
2020-03-30 03:06:06.855 MSK [30816] LOG: redo starts at 0/4F4DE850
2020-03-30 03:06:06.855 MSK [30816] LOG: invalid record length at 0/4F4DE888: wanted 24, got 0
2020-03-30 03:06:06.855 MSK [30816] LOG: redo done at 0/4F4DE850
2020-03-30 03:06:06.862 MSK [37356] LOG: database system is ready to accept connections
我在我的 OS X Catalina 笔记本电脑上运行所有东西并使用 PostgreSQL 12 EnterpriseDB。
以防万一它很重要 - 我创建了一个大表COPY
,在我的 Python 脚本中发送了几个大型 CSV 查询。这些错误的原因是什么?
此平台和版本上存在与 JIT 相关的问题,导致您报告的那种崩溃。邮件列表中对此进行了解释:
Re: PG v12.2 - 设置 jit_above_cost 导致服务器崩溃
目前,解决方法似乎要
set jit = off
等到 EDB 发布带有修复的新版本,希望在 PostgreSQL 12.3 中