On Wed, Jun 22, 2011 at 10:40 PM, Jeff Davis <pgsql@j-davis.com> wrote:
> 1. Torn pages -- not a problem because it's a single bit and idempotent.
Right.
> 2. PD_ALL_VISIBLE bit makes it to disk before a WAL record representing
> an action that makes the page all-visible. Depending on what action
> makes a page all-visible:
> a. An old snapshot is released -- not a problem, because if there is a
> crash all snapshots are released.
> b. Cleanup action on the page -- not a problem, because that will
> create a WAL record and update the page's LSN before setting the
> PD_ALL_VISIBLE.
Lazy VACUUM is the only thing that makes a page all visible. I don't
understand the part about snapshots.
--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company