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@momjian.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.