pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Justin Pryzby <pryzby@telsasoft.com>
To: Guillaume Lelarge <guillaume@lelarge.info>
Cc: pgsql-hackers@postgresql.org, "Dr. Michael Meskes" <michael.meskes@credativ.com>
Subject: Re: Probable memory leak with ECPG and AIX
Date: Sat, 11 Dec 2021 00:52:36 -0600
Message-ID: <20211211065235.GL17618@telsasoft.com> (raw)
In-Reply-To: <CAECtzeWMVW=b8=DJje_4F=OG9BeYLh-phLcCxZ-FBpii+O=SBQ@mail.gmail.com>
References: <CAECtzeWMVW=b8=DJje_4F=OG9BeYLh-phLcCxZ-FBpii+O=SBQ@mail.gmail.com>

On Fri, Dec 10, 2021 at 03:40:50PM +0100, Guillaume Lelarge wrote:
> Hello,
> 
> Our customer thinks he has found a memory leak on ECPG and AIX.
> 
> The code is quite simple. It declares a cursor, opens it, and fetches the
> only line available in the table many times. After some time, the client
> crashes with a segfault error. According to him, it consumed around 256MB.
> What's weird is that it works great on Linux, but crashed on AIX. One
> coworker thought it could be the compiler. Our customer used cc, but he
> also tried with gcc, and got the same error.

A memory leak isn't the same as a segfault (although I don't know how AIX
responds to OOM).

Can you show that it's a memory leak ?  Show RAM use increasing continuously
and linearly with loop count.

How many loops does it take to crash ?

Could you obtain a backtrace ?

-- 
Justin





view thread (20+ messages)  latest in thread

Message-ID: <20211211065235.GL17618@telsasoft.com>
Permalink:  ../20211211065235.GL17618@telsasoft.com/
Also on:    postgresql.org/message-id/20211211065235.GL17618@telsasoft.com

 · 

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-hackers@postgresql.org
  Cc: pryzby@telsasoft.com, guillaume@lelarge.info, michael.meskes@credativ.com
  Subject: Re: Probable memory leak with ECPG and AIX
  In-Reply-To: <20211211065235.GL17618@telsasoft.com>

* 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