pg_dump and not MVCC-safe commands

From: PetSerAl <petseral(at)gmail(dot)com>
To: pgsql-general(at)lists(dot)postgresql(dot)org
Subject: pg_dump and not MVCC-safe commands
Date: 2024-05-19 02:24:28
Message-ID: CAKygsHQHhd4rzYcNCd8OJMH46saT1E+9+5MT2CgOCGgf_yaQAw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

How pg_dump interact with not MVCC-safe commands?

As I understand, pg_dump first take snapshot and then lock all tables
it intended to dump. What happens if not MVCC-safe command committed
after snapshot but before lock? From comment to pg_dump.c I understand
that it may fail with 'cache lookup failed' error. But, can it happen,
that pg_dump not fail, but instead capture inconsistent dump? For
example TRUNCATE committed after snapshot and pg_dump will see result
of TRUNCATE but not result of other commands in TRUNCATE transaction?

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Rich Shepard 2024-05-19 16:54:46 Updating 457 rows in a table
Previous Message Rich Shepard 2024-05-18 15:41:26 Re: Left join syntax error