Re: BUG #15376: Postgres sql 9.4.19 pg_upgrade stops with error The source cluster was not shut down cleanly.

From: kalyani kaniganti <kalyanithumati(at)gmail(dot)com>
To: Bruce Momjian <bruce(at)momjian(dot)us>
Cc: pgsql-bugs(at)lists(dot)postgresql(dot)org
Subject: Re: BUG #15376: Postgres sql 9.4.19 pg_upgrade stops with error The source cluster was not shut down cleanly.
Date: 2018-09-12 01:21:44
Message-ID: CACAAi_6c4hhhxFnUnerrBsfkS1+9CFBt79ORgp_8m6+Snck0Qw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Hi Bruce,
I have a query,in our case old db is not getting shutdown cleanly .May I
know why the DB is unable to shutdown cleanly and this happens repeatedly
.How we can recover the cluster state going to in production state after
stopping the cluster.

BR,a
Kalyani.k

On Tue, Sep 11, 2018, 10:39 PM kalyani kaniganti <kalyanithumati(at)gmail(dot)com>
wrote:

> Hi Bruce,
> Thanks for the info.
> But the problem ,if we repeat the same steps some time old cluster isgoing
> in to in production state.Which is not recoverable after start and stop
> using pg_ctl command.
> How can we can check this case before upgrading to the latest release.
>
> Any suggestions ?
>
> BR,
> Kalyani.k
>
>
>
>
> On Tue, Sep 11, 2018, 9:48 PM Bruce Momjian <bruce(at)momjian(dot)us> wrote:
>
>> On Tue, Sep 11, 2018 at 08:57:26PM +0530, kalyani kaniganti wrote:
>> > Hi Bruce,
>> > Issue is solved after performing below steps
>> >
>> > pgctl start -D <old data folder>
>> > pgctl stop -D <old data folder>
>>
>> Yes, I suspected this would fix it. You were shutdown, so pg_ctl stop
>> had no effect. Starting it and then shutting it down properly fixed it.
>>
>> To summarize, you should never have been able to do upgrades without a
>> clean shutdown. 9.4.17 allowed it, but shouldn't have. This was fixed
>> in 9.4.19 throwing an error in such cases.
>>
>> When the server is not cleanly shut down, there are potentially changes
>> in the WAL that were not replayed on startup into the shared buffers and
>> disk storage, so you could lose transaction or have an inconsistent
>> database. This was prevented in 9.4.19.
>>
>> > But we tried to reinstall the postgressql and checked again. by default
>> the
>> > satndby cluster is going to in production state and while executing the
>> above
>> > commands sometimes the upgarde is working fine and issue is
>> inconsistent.
>> >
>> > Do you have any suggestions.
>>
>> You have still not provided any exact details of how the server was shut
>> down _before_ you ran pg_ctl stop, so I am not to going to bother
>> guessing any further.
>>
>> --
>> Bruce Momjian <bruce(at)momjian(dot)us> http://momjian.us
>> EnterpriseDB http://enterprisedb.com
>>
>> + As you are, so once was I. As I am, so you will be. +
>> + Ancient Roman grave inscription +
>>
>

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Michael Paquier 2018-09-12 02:27:44 Re: BUG #15376: Postgres sql 9.4.19 pg_upgrade stops with error The source cluster was not shut down cleanly.
Previous Message Alexander Korotkov 2018-09-11 21:26:54 Re: BUG #15378: SP-GIST memory context screwup?