From: | Kyotaro Horiguchi <horikyota(dot)ntt(at)gmail(dot)com> |
---|---|
To: | thomas(dot)munro(at)gmail(dot)com |
Cc: | tgl(at)sss(dot)pgh(dot)pa(dot)us, boekewurm+postgres(at)gmail(dot)com, alvherre(at)alvh(dot)no-ip(dot)org, pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: standby recovery fails (tablespace related) (tentative patch and discussion) |
Date: | 2022-07-29 05:20:08 |
Message-ID: | 20220729.142008.340873830395327221.horikyota.ntt@gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
At Fri, 29 Jul 2022 11:27:01 +1200, Thomas Munro <thomas(dot)munro(at)gmail(dot)com> wrote in
> Maybe it just needs a replication slot? I see:
>
> ERROR: requested WAL segment 000000010000000000000003 has already been removed
Agreed, I see the same. The same failure can be surely reproducible
by inserting wal-switch+checkpoint after taking backup [1]. And it is
fixed by the attached.
regards.
--
Kyotaro Horiguchi
NTT Open Source Software Center
[1]:
--- a/src/test/recovery/t/033_replay_tsp_drops.pl
+++ b/src/test/recovery/t/033_replay_tsp_drops.pl
@@ -30,6 +30,13 @@ sub test_tablespace
my $backup_name = 'my_backup';
$node_primary->backup($backup_name);
+ $node_primary->psql(
+ 'postgres',
+ qq[
+ CREATE TABLE t(); DROP TABLE t; SELECT pg_switch_wal();
+ CHECKPOINT;
+ ]);
+
my $node_standby = PostgreSQL::Test::Cluster->new("standby2_$strategy");
$node_standby->init_from_backup($node_primary, $backup_name,
has_streaming => 1);
Attachment | Content-Type | Size |
---|---|---|
fix_tsp_drop_test_error.diff | text/x-patch | 516 bytes |
From | Date | Subject | |
---|---|---|---|
Next Message | vignesh C | 2022-07-29 05:21:40 | Re: Handle infinite recursion in logical replication setup |
Previous Message | Tom Lane | 2022-07-29 04:55:17 | Re: generic plans and "initial" pruning |