Re: Change WAL directory via conf - Mailing list pgsql-general

From David G. Johnston
Subject Re: Change WAL directory via conf
Date
Msg-id CAKFQuwb9B85khromJGFTxdbAOTBgRFdOXKgiXMYytttSbw9EMw@mail.gmail.com
Whole thread Raw
In response to Change WAL directory via conf  (Thomas Butz <tbutz@optitool.de>)
List pgsql-general
On Friday, February 27, 2026, Thomas Butz <tbutz@optitool.de> wrote:
Is there a reason why the location of the WAL directory cannot be specified via the configuration?
The documentation describes a workaround using a symbolic link, which I find rather awkward:

https://www.postgresql.org/docs/current/wal-internals.html

Why is there no wal_directory analogous to data_directory?

WAL is data in the sense of what data_directory covers.  Both it and the main files can be placed outside the physical directory so long as those external locations can be navigated to by symbolic links.  The fact initdb provides for this means it’s supported just fine.  Just no one has bothered to make a server program to perform that same work post-initdb.  An SQL command is not possible though, we aren’t going to be able to move WAL while the server is running for hopefully self-evident reasons.

David J.

pgsql-general by date:

Previous
From: "David G. Johnston"
Date:
Subject: Re: Default values in the docs
Next
From: Laurenz Albe
Date:
Subject: Re: Timezone handling with timestamp without time zone columns