Thread: Query about pg_wal directory filled up

Query about pg_wal directory filled up

From
Rama Krishnan
Date:

Hi Team,

One of our clients recently migrated from Oracle to PostgreSQL and is conducting multiple scenarios to understand PostgreSQL behavior.  

One of their main concerns is whether the database will allow `INSERT` queries when the `pg_wal` directory becomes full.  

As I understand, once the `pg_wal` directory is completely filled, the database will allow only read queries and will not permit any write operations.  

Kindly advise


Thanks
RK

Re: Query about pg_wal directory filled up

From
Laurenz Albe
Date:
On Tue, 2024-12-17 at 19:11 +0530, Rama Krishnan wrote:
> One of their main concerns is whether the database will allow `INSERT` queries
> when the `pg_wal` directory becomes full.  
>
> As I understand, once the `pg_wal` directory is completely filled, the database
> will allow only read queries and will not permit any write operations.  

That is not the case.  If pg_wal fills up (more precisely: if creating a new
file in pg_wal fails), PostgreSQL will crash and go down.

Yours,
Laurenz Albe



Re: Query about pg_wal directory filled up

From
Saul Perdomo
Date:


On Wed, Dec 18, 2024, 5:01 a.m. Rama Krishnan <raghuldrag@gmail.com> wrote:

Hi Team,

One of our clients recently migrated from Oracle to PostgreSQL and is conducting multiple scenarios to understand PostgreSQL behavior.  

One of their main concerns is whether the database will allow `INSERT` queries when the `pg_wal` directory becomes full.  


The way out of this "conundrum" is to make sure to implement a solid backup process. 

I'm a huge fan of PGBackRest:




Kindly advise


Thanks
RK