Re: Proposing pg_hibernate - Mailing list pgsql-hackers

From Amit Kapila
Subject Re: Proposing pg_hibernate
Date
Msg-id CAA4eK1LByHmxrLP+djEMfSD9vKqxQnVyFWsMuhE-TF3hgWzPzw@mail.gmail.com
Whole thread Raw
In response to Re: Proposing pg_hibernate  (Gurjeet Singh <gurjeet@singh.im>)
Responses Re: Proposing pg_hibernate  (Gurjeet Singh <gurjeet@singh.im>)
List pgsql-hackers
On Wed, May 28, 2014 at 7:31 AM, Gurjeet Singh <gurjeet@singh.im> wrote:
 > Caveats
> --------------
>
> - Buffer list is saved only when Postgres is shutdown in "smart" and
> "fast" modes.
>
>     That is, buffer list is not saved when database crashes, or on "immediate"
>     shutdown.
>
> - A reduction in `shared_buffers` is not detected.
>
>     If the `shared_buffers` is reduced across a restart, and if the combined
>     saved buffer list is larger than the new shared_buffers, Postgres
>     Hibernator continues to read and restore blocks even after `shared_buffers`
>     worth of buffers have been restored.

How about the cases when shared buffers already contain some
data:
a. Before Readers start filling shared buffers, if this cluster wishes
to join replication as a slave and receive the data from master, then
this utility might need to evict some buffers filled during startup
phase.
b. As soon as the server completes startup (reached consistent
point), it allows new connections which can also use some shared
buffers before Reader process could use shared buffers or are you
planing to change the time when users can connect to database.  

I am not sure if replacing shared buffer contents in such cases can
always be considered useful.

With Regards,
Amit Kapila.
EnterpriseDB: http://www.enterprisedb.com

pgsql-hackers by date:

Previous
From: Amit Kapila
Date:
Subject: Re: Spreading full-page writes
Next
From: Andrew Dunstan
Date:
Subject: Re: json casts