Re: Crash by targetted recovery

2020-03-09 Thread Kyotaro Horiguchi
(Hmm. My sight must be as short as 2 word length..) At Tue, 10 Mar 2020 14:59:00 +0900 (JST), Kyotaro Horiguchi wrote in > In the first place the "seg" is "fileno". Honestly I don't think the > test doesn't reach to fileno boundary but I did in the attached. Since Of course it is a mistake of

Re: Crash by targetted recovery

2020-03-09 Thread Kyotaro Horiguchi
At Tue, 10 Mar 2020 10:50:52 +0900, Fujii Masao wrote in > Pushed the v5-0001-Tidy-up-XLogSource-usage.patch! Thanks! > Regarding the remaining patch adding the regression test, I didn't seriously inteneded it to be in the tree. > +$result = > + $node_standby->safe_psql('postgres', "SELECT >

Re: Crash by targetted recovery

2020-03-09 Thread Fujii Masao
On 2020/03/09 15:46, Fujii Masao wrote: On 2020/03/09 13:49, Kyotaro Horiguchi wrote: At Sat, 7 Mar 2020 01:46:16 +0900, Fujii Masao wrote in (It seems retroverting to the first patch when I started this...) The second place covers wider cases so I reverted the first place. Thanks for

Re: Crash by targetted recovery

2020-03-09 Thread Kyotaro Horiguchi
At Mon, 9 Mar 2020 15:46:49 +0900, Fujii Masao wrote in > On 2020/03/09 13:49, Kyotaro Horiguchi wrote: > > At Sat, 7 Mar 2020 01:46:16 +0900, Fujii Masao > >> Regarding 0003 patch, I added a bit more detail comments into > >> the patch so that we can understand the code more easily. > >> Update

Re: Crash by targetted recovery

2020-03-08 Thread Fujii Masao
On 2020/03/09 13:49, Kyotaro Horiguchi wrote: At Sat, 7 Mar 2020 01:46:16 +0900, Fujii Masao wrote in (It seems retroverting to the first patch when I started this...) The second place covers wider cases so I reverted the first place. Thanks for updating the patch that way. Not sure which

Re: Crash by targetted recovery

2020-03-08 Thread Kyotaro Horiguchi
At Sat, 7 Mar 2020 01:46:16 +0900, Fujii Masao wrote in > > (It seems retroverting to the first patch when I started this...) > > The second place covers wider cases so I reverted the first place. > > Thanks for updating the patch that way. > Not sure which patch you're mentioning, though. Tha

Re: Crash by targetted recovery

2020-03-06 Thread Fujii Masao
On 2020/03/06 10:29, Kyotaro Horiguchi wrote: At Thu, 5 Mar 2020 19:51:11 +0900, Fujii Masao wrote in On 2020/03/05 12:08, Kyotaro Horiguchi wrote: I understand that the reconnection for REDO record is useless. Ok I take the !StandbyMode way. The attached is the test script that is change

Re: Crash by targetted recovery

2020-03-05 Thread Kyotaro Horiguchi
At Thu, 5 Mar 2020 19:51:11 +0900, Fujii Masao wrote in > > > On 2020/03/05 12:08, Kyotaro Horiguchi wrote: > > I understand that the reconnection for REDO record is useless. Ok I > > take the !StandbyMode way. > > The attached is the test script that is changed to count the added > > test, an

Re: Crash by targetted recovery

2020-03-05 Thread Fujii Masao
On 2020/03/05 12:08, Kyotaro Horiguchi wrote: At Mon, 2 Mar 2020 20:54:04 +0900, Fujii Masao wrote in And random access during StandbyMode ususally (always?) lets RecPtr go back. I'm not sure WaitForWALToBecomeAvailable works correctly if we don't have a file in pg_wal and the REDO point i

Re: Crash by targetted recovery

2020-03-04 Thread Kyotaro Horiguchi
At Mon, 2 Mar 2020 20:54:04 +0900, Fujii Masao wrote in > > And random access during StandbyMode ususally (always?) lets RecPtr go > > back. I'm not sure WaitForWALToBecomeAvailable works correctly if we > > don't have a file in pg_wal and the REDO point is far back by more > > than a segment f

Re: Crash by targetted recovery

2020-03-02 Thread Fujii Masao
On 2020/02/28 12:13, Kyotaro Horiguchi wrote: At Thu, 27 Feb 2020 20:04:41 +0900, Fujii Masao wrote in On 2020/02/27 17:05, Kyotaro Horiguchi wrote: Thank you for the comment. At Thu, 27 Feb 2020 16:23:44 +0900, Fujii Masao wrote in On 2020/02/27 15:23, Kyotaro Horiguchi wrote: I fail

Re: Crash by targetted recovery

2020-02-27 Thread Kyotaro Horiguchi
At Thu, 27 Feb 2020 20:04:41 +0900, Fujii Masao wrote in > > > On 2020/02/27 17:05, Kyotaro Horiguchi wrote: > > Thank you for the comment. > > At Thu, 27 Feb 2020 16:23:44 +0900, Fujii Masao > > wrote in > >> On 2020/02/27 15:23, Kyotaro Horiguchi wrote: > I failed to understand why ran

Re: Crash by targetted recovery

2020-02-27 Thread Fujii Masao
On 2020/02/27 17:05, Kyotaro Horiguchi wrote: Thank you for the comment. At Thu, 27 Feb 2020 16:23:44 +0900, Fujii Masao wrote in On 2020/02/27 15:23, Kyotaro Horiguchi wrote: I failed to understand why random access while reading from stream is bad idea. Could you elaborate why? It seems

Re: Crash by targetted recovery

2020-02-27 Thread Kyotaro Horiguchi
Thank you for the comment. At Thu, 27 Feb 2020 16:23:44 +0900, Fujii Masao wrote in > On 2020/02/27 15:23, Kyotaro Horiguchi wrote: > >> I failed to understand why random access while reading from > >> stream is bad idea. Could you elaborate why? > > It seems to me the word "streaming" suggests

Re: Crash by targetted recovery

2020-02-26 Thread Fujii Masao
On 2020/02/27 15:23, Kyotaro Horiguchi wrote: At Thu, 27 Feb 2020 14:40:55 +0900, Fujii Masao wrote in On 2020/02/27 12:48, Kyotaro Horiguchi wrote: Hello. We found that targetted promotion can cause an assertion failure. The attached TAP test causes that. TRAP: FailedAssertion("Stand

Re: Crash by targetted recovery

2020-02-26 Thread Kyotaro Horiguchi
At Thu, 27 Feb 2020 14:40:55 +0900, Fujii Masao wrote in > > > On 2020/02/27 12:48, Kyotaro Horiguchi wrote: > > Hello. > > We found that targetted promotion can cause an assertion failure. The > > attached TAP test causes that. > > > >> TRAP: FailedAssertion("StandbyMode", File: "xlog.c", L

Re: Crash by targetted recovery

2020-02-26 Thread Fujii Masao
On 2020/02/27 12:48, Kyotaro Horiguchi wrote: Hello. We found that targetted promotion can cause an assertion failure. The attached TAP test causes that. TRAP: FailedAssertion("StandbyMode", File: "xlog.c", Line: 12078) After recovery target is reached, StartupXLOG turns off standby mode

Crash by targetted recovery

2020-02-26 Thread Kyotaro Horiguchi
Hello. We found that targetted promotion can cause an assertion failure. The attached TAP test causes that. > TRAP: FailedAssertion("StandbyMode", File: "xlog.c", Line: 12078) After recovery target is reached, StartupXLOG turns off standby mode then refetches the last record. If the last record