Pragati Agarwal
Pragati Agarwal

Reputation: 53

Postgresql error : PANIC: could not locate a valid checkpoint record

In the Datastore logs, I encountered the following error, Not sure what has gone wrong.

[7804] LOG:  starting PostgreSQL 13.1, compiled by Visual C++ build 1914, 64-bit
2021-08-23 22:56:15.980 CEST [7804] LOG:  listening on IPv4 address "127.0.0.1", port 9003
2021-08-23 22:56:15.983 CEST [7804] LOG:  listening on IPv4 address "10.91.198.36", port 9003
2021-08-23 22:56:16.041 CEST [8812] LOG:  database system was shut down at 2021-08-23 22:54:51 CEST
2021-08-23 22:56:16.044 CEST [8812] LOG:  invalid primary checkpoint record
2021-08-23 22:56:16.045 CEST [8812] PANIC:  could not locate a valid checkpoint record
2021-08-23 22:56:16.076 CEST [7804] LOG:  startup process (PID 8812) was terminated by exception 0xC0000409
2021-08-23 22:56:16.076 CEST [7804] HINT:  See C include file "ntstatus.h" for a description of the hexadecimal value.
2021-08-23 22:56:16.078 CEST [7804] LOG:  aborting startup due to startup process failure
2021-08-23 22:56:16.094 CEST [7804] LOG:  database system is shut down

Upvotes: 3

Views: 1951

Answers (1)

Laurenz Albe
Laurenz Albe

Reputation: 246348

Somebody deleted crucial WAL files (to free space?), and now your cluster is corrupted

Restore from backup. If you have no backup, running pg_resetwal is an option, since it seems there was a clean shutdown.

Upvotes: 2

Related Questions