Re: Correct SQLSTATE for ENOMEM in file access

From: Alexander Kuzmenkov <akuzmenkov(at)timescale(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Correct SQLSTATE for ENOMEM in file access
Date: 2024-02-02 19:28:39
Message-ID: CALzhyqwg-atPhwH3jeNQdrnj5eP2mvx-TaBo3w1r82vzBrC9QA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Fri, Feb 2, 2024 at 8:12 PM Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> Hmm, do you think this is actually reachable? AFAIK we should only be
> calling errcode_for_file_access() after functions that are unlikely to
> report ENOMEM.

It's reachable, that's how I noticed. I'm seeing logs like "XX000:
could not load library \"/usr/lib/postgresql/15/lib/plpgsql.so\": out
of memory" from internal_load_library and so on. Not sure what is the
exact configuration required to reproduce this, probably at least the
overcommit should be disabled.

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Heikki Linnakangas 2024-02-02 19:32:36 Re: ResourceOwner refactoring
Previous Message Tom Lane 2024-02-02 19:12:13 Re: Correct SQLSTATE for ENOMEM in file access