From: | James Sebastian <james(dot)sebastian(at)gmail(dot)com> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | pgsql-novice(at)postgresql(dot)org |
Subject: | Re: Possible Corrputed shared memory |
Date: | 2015-08-01 14:34:12 |
Message-ID: | CA+ehAmH069J3D17ZFg745hOgLy0nmW0bCg+=V4Skj-0bcGMa4Q@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-novice |
On 1 August 2015 at 19:43, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> James Sebastian <james(dot)sebastian(at)gmail(dot)com> writes:
> > I attempted application stop and database shutdown using init scripts
> > followed by start.
> > The database failed to restart with the following error.
>
> > 2015-07-30 14:14:17 IST LOG: received immediate shutdown request
> > ...
>
> > The whole recovery took more than 2.5 hours to complete to come back to a
> > state to accept connections back. This caused considerable disruption in
> > normal service.
>
> If you use "immediate" mode shutdown, then yes, crash recovery is what
> will ensue. Think of that as being like the large red panic button that
> dumps the fuel rods out of a nuclear reactor: you push that button only
> when disaster is otherwise certain, because recovering will be slow and
> expensive.
>
> For an ordinary clean shutdown, you use "fast" mode, or "smart" mode
> if you're not expecting any long-lived client sessions.
>
> (If you're using a wrapper script that defaults to "immediate" mode,
> I'd advise changing that default.)
>
I am using default /etc/init.d/postgresql start|stop scripts.
I will check if it is using ordinary clean shutdown
>
> Also, if it took that long to recover, you might have raised the
> checkpoint interval settings too high.
>
I am using the following parameters
checkpoint_segments = 10 (from OS default 3)
checkpoint_completion_target = 0.8 (from OS default 0.5)
archive_mode=on
archive_timeout=600
Does any of the above looks too high ?
Regards,
James
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2015-08-01 14:40:57 | Re: Possible Corrputed shared memory |
Previous Message | Tom Lane | 2015-08-01 14:13:18 | Re: Possible Corrputed shared memory |