Re: Race condition in recovery?

Robert Haas <robertmhaas@gmail.com>

From: Robert Haas <robertmhaas@gmail.com>
To: Kyotaro Horiguchi <horikyota.ntt@gmail.com>
Cc: Dilip Kumar <dilipbalaut@gmail.com>, hlinnaka <hlinnaka@iki.fi>, PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2021-06-04T14:56:12Z
Lists: pgsql-hackers

Attachments

On Fri, Jun 4, 2021 at 5:25 AM Kyotaro Horiguchi
<horikyota.ntt@gmail.com> wrote:
> I think that's right. And the test script detects the issue for me
> both on Linux but doesn't work for Windows.
>
> '"C:/../Documents/work/postgresql/src/test/recovery/t/cp_history_files"' is not recognized as an internal command or external command ..

Hmm, that's a problem. Can you try the attached version?

> + # clean up
> + $node_primary->teardown_node;
> + $node_standby->teardown_node;
> + $node_cascade->teardown_node;
>
> I don't think explicit teardown is useless as the final cleanup.

I don't know what you mean by this. If it's not useless, good, because
we're doing it. Or do you mean that you think it is useless, and we
should remove it?

> By the way the attached patch is named as "Fix-corner-case..." but
> doesn't contain the fix. Is it intentional?

No, that was a goof.

-- 
Robert Haas
EDB: http://www.enterprisedb.com

Commits

  1. Further refinement of stuck_on_old_timeline recovery test

  2. Adjust new test case to set wal_keep_segments.

  3. Adjust new test case to set wal_keep_size.

  4. Fix corner case failure of new standby to follow new primary.

  5. Back-port a few PostgresNode.pm methods.

  6. Allow PostgresNode.pm's backup method to accept backup_options.

  7. Add end-to-end testing of pg_basebackup's tar-format output.

  8. Allow PostgresNode.pm tests to wait for catchup

  9. Delay reading timeline history file until it's fetched from master.