Re: BUG #13077: when standby crash and restart, it's need next timeline history file, but upstream node normal.

From: Jeff Janes <jeff(dot)janes(at)gmail(dot)com>
To: 德哥 <digoal(at)126(dot)com>
Cc: hlinnaka(at)iki(dot)fi, Pg Bugs <pgsql-bugs(at)postgresql(dot)org>
Subject: Re: BUG #13077: when standby crash and restart, it's need next timeline history file, but upstream node normal.
Date: 2015-04-18 17:30:31
Message-ID: CAMkU=1wHVvQx9wj+qozk+NByGLwAfxOo1EDBF+uCPfCr+9uMxA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

On Fri, Apr 17, 2015 at 5:39 PM, 德哥 <digoal(at)126(dot)com> wrote:

> but in my environment, C need the new timeline file, i can see the
> restore command display about copy 0000002.history from my setted dir (NFS
> from remote computer) use top or ps command.
> And the copy message display forever.
> ps:
> I restart the C compute, and NFS it's ok, recovery it's ok, and don't need
> the 0000002.history file.
>
> When postgresql crashed, it need copy new history first whatever it's
> really need the file?
>

It needs to know whether the file exists or not. Rather than asking if the
file exists, and then separately asking for a copy of it, instead it just
asks for a copy of the file and see if it gets returned an error or not.

If your restore_command hangs up forever when asked for a file that doesn't
exist, then there is something wrong with your restore command.

As explained in the documentation, "It is important for the command to
return a zero exit status only if it succeeds. The command will be asked
for file names that are not present in the archive; it must return nonzero
when so asked"

Cheers,

Jeff

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message 德哥 2015-04-18 18:45:30 Re: BUG #13077: when standby crash and restart, it's need next timeline history file, but upstream node normal.
Previous Message 德哥 2015-04-18 00:39:02 Re: BUG #13077: when standby crash and restart, it's need next timeline history file, but upstream node normal.