数据库意外中止,无法启动

文章目录

环境

系统平台:N/A

版本:4.1.1

症状

使用过程中数据库突然中止,且无法启动,存在一些类似报错信息:

LOG: checkpoints are occurring too frequently (7 seconds apart)

HINT: Consider increasing the configuration parameter "checkpoint_segments".

PANIC: could not write to file "pg_xlog/xlogtemp.9028": No space left on device

STATEMENT: insert into t1 select generate_series(1,1000000),'nan',md5('highgo');

PANIC: could not write to file "pg_xlog/xlogtemp.9028": No space left on device

server closed the connection unexpectedly

This probably means the server terminated abnormally

before or while processing the request.

The connection to the server was lost. Attempting reset: LOG: server process (PID 9028) was terminated by signal 6: Aborted

DETAIL: Failed process was running: insert into t1 select * from t2;

LOG: terminating any other active server processes

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.

Failed.

!> LOG: all server processes terminated; reinitializing

LOG: database system was interrupted; last known up at 2017-12-04 18:05:09 CST

LOG: database system was not properly shut down; automatic recovery in progress

LOG: redo starts at 0/103FE040

LOG: redo done at 0/14FFFF68

LOG: last completed transaction was at log time 2017-12-04 18:05:09.85515+08

PANIC: could not write to file "pg_xlog/xlogtemp.9084": No space left on device

LOG: startup process (PID 9084) was terminated by signal 6: Aborted

LOG: aborting startup due to startup process failure


LOG: database system shutdown was interrupted; last known up at 2017-12-04 18:05:23 CST

LOG: database system was not properly shut down; automatic recovery in progress

LOG: redo starts at 0/103FE040

LOG: redo done at 0/14FFFF68

LOG: last completed transaction was at log time 2017-12-04 18:05:09.85515+08

PANIC: could not write to file "pg_xlog/xlogtemp.9138": No space left on device

LOG: startup process (PID 9138) was terminated by signal 6: Aborted

LOG: aborting startup due to startup process failure

问题原因

wal日志所在文件系统空间不足。

解决方案

清理该文件系统下过期的临时文件,或将wal日志存放至更大的系统空间中。

注意:严禁删除wal日志!

相关推荐
IvorySQL12 小时前
PostgreSQL 技术日报 (3月6日)|为什么 Ctrl-C 在 psql 里让人不安?
数据库·postgresql·开源
NineData13 小时前
数据库管理工具NineData,一年进化成为数万+开发者的首选数据库工具?
运维·数据结构·数据库
IvorySQL18 小时前
PostgreSQL 技术日报 (3月5日)|规划器控制力升级,内核能力再进阶
数据库·postgresql·开源
数据组小组1 天前
免费数据库管理工具深度横评:NineData 社区版、Bytebase 社区版、Archery,2026 年开发者该选哪个?
数据库·测试·数据库管理工具·数据复制·迁移工具·ninedata社区版·naivicat平替
悟空聊架构2 天前
基于KaiwuDB在游乐场“刷卡+投币”双模消费系统中的落地实践
数据库·后端·架构
IvorySQL2 天前
PostgreSQL 技术日报 (3月4日)|硬核干货 + 内核暗流一网打尽
数据库·postgresql·开源
进击的丸子2 天前
虹软人脸服务器版SDK(Linux/ARM Pro)多线程调用及性能优化
linux·数据库·后端
NineData2 天前
NineData智能数据管理平台新功能发布|2026年1-2月
数据库·sql·数据分析
IvorySQL2 天前
双星闪耀温哥华:IvorySQL 社区两项议题入选 PGConf.dev 2026
数据库·postgresql·开源