|From:||Nathan Bossart <nathandbossart(at)gmail(dot)com>|
|To:||Robert Haas <robertmhaas(at)gmail(dot)com>|
|Subject:||Re: avoid multiple hard links to same WAL file after a crash|
|Views:||Raw Message | Whole Thread | Download mbox | Resend email|
On Fri, Apr 08, 2022 at 10:38:03AM -0400, Robert Haas wrote:
> I'd actually be in favor of nuking durable_rename_excl() from orbit
> and putting the file-exists tests in the callers. Otherwise, someone
> might assume that it actually has the semantics that its name
> suggests, which could be pretty disastrous. If we don't want to do
> that, then I'd changing to do the stat-then-durable-rename thing
> internally, so we don't leave hard links lying around in *any* code
> path. Perhaps that's the right answer for the back-branches in any
> case, since there could be third-party code calling this function.
I've attached a patch that simply removes durable_rename_excl() and
replaces existing calls with durable_rename(). I noticed that Andres
expressed similar misgivings about durable_rename_excl() last year  .
I can create a stat-then-durable-rename version of this for back-patching
if that is still the route we want to go.
Amazon Web Services: https://aws.amazon.com
|Next Message||Nathan Bossart||2022-04-08 20:18:57||Re: Avoid erroring out when unable to remove or parse logical rewrite files to save checkpoint work|
|Previous Message||Peter Geoghegan||2022-04-08 19:30:46||Re: Lowering the ever-growing heap->pd_lower|