Re: Hot standby doesn't come up on some situation. - Mailing list pgsql-hackers

From Andres Freund
Subject Re: Hot standby doesn't come up on some situation.
Date
Msg-id 20140228090730.GI15628@awork2.anarazel.de
Whole thread Raw
In response to Hot standby doesn't come up on some situation.  (Kyotaro HORIGUCHI <horiguchi.kyotaro@lab.ntt.co.jp>)
Responses Re: Hot standby doesn't come up on some situation.  (Kyotaro HORIGUCHI <kyota.horiguchi@gmail.com>)
List pgsql-hackers
On 2014-02-28 17:55:21 +0900, Kyotaro HORIGUCHI wrote:
> The recovery process stays on 'incosistent' state forever when
> the server has crashed before any wal record is inserted after
> the last checkpoint.

> # killall postgres
> # rm -rf $PGDATA/*
> initdb
> pg_ctl start -w
> sleep 1
> pg_ctl stop -m i
> cat > $PGDATA/recovery.conf <<EOF
> standby_mode = 'on'
> primary_conninfo = 'host=localhost port=9999 user=repuser application_name=pm01 keepalives_idle=60
keepalives_interval=5keepalives_count=5'
 
> #restore_command = '/bin/true'
> recovery_target_timeline = 'latest'
> EOF
> cat >> $PGDATA/postgresql.conf <<EOF
> #log_min_messages = debug5
> hot_standby = on
> EOF
> pg_ctl start

Uh. So, if I understand correctly, what you did is to convert a normal
live pg, into a replica that doesn't have a upstream node, right?
Normally the primary will just do an additional write shortly
afterwards, resolving this situation?

Greetings,

Andres Freund

-- Andres Freund                       http://www.2ndQuadrant.com/PostgreSQL Development, 24x7 Support, Training &
Services



pgsql-hackers by date:

Previous
From: Kyotaro HORIGUCHI
Date:
Subject: Re: Hot standby doesn't come up on some situation.
Next
From: Kyotaro HORIGUCHI
Date:
Subject: Re: Hot standby doesn't come up on some situation.