pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Jelte Fennema <postgres@jeltef.nl>
Cc: Michael Paquier <michael@paquier.xyz>
Cc: duspensky@ya.ru
Cc: pgsql-bugs@lists.postgresql.org
Subject: Re: BUG #16160: Minor memory leak in case of starting postgres server with SSL encryption
Date: Tue, 16 Mar 2021 12:31:17 -0400
Message-ID: <3255514.1615912277@sss.pgh.pa.us> (raw)
In-Reply-To: <CAGECzQTucR20CLwb6mw_JLdVST8GqYNqYr1OmAnNS2Byg8r+dg@mail.gmail.com>
References: <16160-18367e56e9a28264@postgresql.org>
	<20191213063915.GE1942@paquier.xyz>
	<20191214092456.GB70616@paquier.xyz>
	<CAGECzQTucR20CLwb6mw_JLdVST8GqYNqYr1OmAnNS2Byg8r+dg@mail.gmail.com>

Jelte Fennema <postgres@jeltef.nl> writes:
> We ran into this memory leak on PG11 in production. The lea was determined
> to be the root cause of OOM errors we were seeing. There was a combination
> of a things that caused this leak to become serious enough for these OOM
> errors to happen:

I follow the argument that a leak in the postmaster's SIGHUP processing
could accumulate enough to be a problem.  However, how sure are you
really that this specific bug accounts for all of the leakage you saw?

I'm wondering about that because I see some other stuff in be_tls_init()
that looks like it might get leaked, notably the root_cert_list read
from the ssl_ca_file.  This code was originally meant to be run exactly
once at postmaster start, so it's not too surprising that it's not as
careful as it now needs to be.

			regards, tom lane





view thread (16+ messages)  latest in thread

Message-ID: <3255514.1615912277@sss.pgh.pa.us>
Permalink:  ../3255514.1615912277@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/3255514.1615912277@sss.pgh.pa.us

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-bugs@postgresql.org
  Cc: tgl@sss.pgh.pa.us, postgres@jeltef.nl, michael@paquier.xyz, duspensky@ya.ru, pgsql-bugs@lists.postgresql.org
  Subject: Re: BUG #16160: Minor memory leak in case of starting postgres server with SSL encryption
  In-Reply-To: <3255514.1615912277@sss.pgh.pa.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox