Re: 011_crash_recovery.pl intermittently fails

From: Kyotaro Horiguchi <horikyota(dot)ntt(at)gmail(dot)com>
To: tgl(at)sss(dot)pgh(dot)pa(dot)us
Cc: thomas(dot)munro(at)gmail(dot)com, pg(at)bowt(dot)ie, pgsql-hackers(at)lists(dot)postgresql(dot)org, craig(dot)ringer(at)enterprisedb(dot)com, robertmhaas(at)gmail(dot)com
Subject: Re: 011_crash_recovery.pl intermittently fails
Date: 2021-03-05 07:51:17
Message-ID: 20210305.165117.1192284154251506643.horikyota.ntt@gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

At Thu, 04 Mar 2021 23:40:34 -0500, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote in
> BTW, I tried simply removing the "allows_streaming" option from
> the test, and it failed ten times out of ten tries for me.
> So Andres is right that that makes it pretty reproducible in
> a stock build.

The difference comes from the difference of shared_buffers. In the
"allows_streaming" case, PostgresNode::init() *reduces* the number
down to '1MB'(128 blocks) which leads to only 8 XLOGbuffers, which
will very soon be wrap-arounded, which leads to XLogWrite.

When allows_streaming=0 case, the default size of shared_buffers is
128MB (16384 blocks). WAL buffer (512) doesn't get wrap-arounded
during the test and no WAL buffer is written out in that case.

regards.

--
Kyotaro Horiguchi
NTT Open Source Software Center

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Kyotaro Horiguchi 2021-03-05 07:57:40 Re: 011_crash_recovery.pl intermittently fails
Previous Message Michael Paquier 2021-03-05 07:38:17 Re: Which PG version does CVE-2021-20229 affected?