Re: pg_rewind WAL segments deletion pitfall

From: Alexander Kukushkin <cyberdemn(at)gmail(dot)com>
To: torikoshia <torikoshia(at)oss(dot)nttdata(dot)com>
Cc: Kyotaro Horiguchi <horikyota(dot)ntt(at)gmail(dot)com>, michael(at)paquier(dot)xyz, pgsql-hackers(at)postgresql(dot)org, bungina(at)gmail(dot)com, pgsql-hackers(at)lists(dot)postgresql(dot)org
Subject: Re: pg_rewind WAL segments deletion pitfall
Date: 2023-09-12 13:29:46
Message-ID: CAFh8B=m0TuTNyPzOC6zWrVH2iOEnuNyuPSazqTgjVbd=nt3B2Q@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs pgsql-hackers

Hi,

Please find attached v5.
What changed:
1. Now we collect which files should be kept in a separate hash table.
2. Decision whether to keep the file is made only when the file is actually
missing on the source. That is, remaining WAL files will be copied over as
it currently is, although it could be extremely inefficient and unnecessary.
3. Added TAP test that actually at least one file isn't removed.

Regards,
--
Alexander Kukushkin

Attachment Content-Type Size
v5-0001-pg_rewind-wal-deletion.patch text/x-patch 7.6 KB

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Aleksandr Vinokurov 2023-09-12 16:59:43 "as name" is shadowed by name "value" when selecting with "left join jsonb_array_elements(d.items) as item on true"
Previous Message Amit Kapila 2023-09-12 10:43:47 Re: [16+] subscription can end up in inconsistent state

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2023-09-12 14:29:26 Re: Document that PG_TRY block cannot have a return statement
Previous Message Zhijie Hou (Fujitsu) 2023-09-12 13:22:50 RE: pg_upgrade and logical replication