Configuration parameter

ignore_invalid_pages — PostgreSQL configuration parameter

Category Developer Options Change scope Postmaster

If set to off (the default), detection of WAL records having references to invalid pages during recovery causes PostgreSQL to raise a PANIC-level error, aborting the recovery.

At a glance

Property Value
Parameter ignore_invalid_pages
Category Developer Options
Default (see documentation)
Value type boolean (on/off)
Change scope Server restart required (postgresql.conf)
Available in PostgreSQL 13, 14, 15, 16, 17, 18, 19 (added in 13)

What it does

If set to off (the default), detection of WAL records having references to invalid pages during recovery causes PostgreSQL to raise a PANIC-level error, aborting the recovery. Setting ignore_invalid_pages to on causes the system to ignore invalid page references in WAL records (but still report a warning), and continue the recovery. This behavior may cause crashes, data loss, propagate or hide corruption, or other serious problems. However, it may allow you to get past the PANIC-level error, to finish the recovery, and to cause the server to start up. The parameter can only be set at server start. It only has effect during recovery or in standby mode.

(Description quoted from the official PostgreSQL documentation.)

How to apply a change

Set it in postgresql.conf (or with ALTER SYSTEM) and restart the server — this parameter cannot change without a restart.

Inspect the current value and source with SHOW ignore_invalid_pages; or SELECT name, setting, unit, context, source FROM pg_settings WHERE name = 'ignore_invalid_pages';.

Tuning guidance

This is a developer and debugging aid, not a performance knob. Leave it at the default in production; enable it only temporarily, on a non-production or carefully controlled system, while diagnosing a specific problem. Several options in this group add overhead, generate large volumes of log output, or can damage data if misused — turn them off again as soon as the investigation is done.

Reference

PostgreSQL documentation — ignore_invalid_pages.

Keep going

Related & next steps

Was this helpful?

← All configuration parameters