From: Vitaly V. Voronov <wizard_1024@tut.by>
To: Peter Geoghegan <pg@bowt.ie>
To: Alvaro Herrera <alvherre@alvh.no-ip.org>
Cc: Andres Freund <andres@anarazel.de>
Cc: PostgreSQL mailing lists <pgsql-bugs@lists.postgresql.org>
Subject: Re: BUG #15144: *** glibc detected *** postgres: postgres smsconsole [local] SELECT: double free or corruption (!pre
Date: Mon, 16 Apr 2018 21:05:37 +0300
Message-ID: <2139451523901937@web24o.yandex.ru> (raw)
In-Reply-To: <CAH2-Wz=RDFQAqczdFezYCuyEHid4eHe6e5uEu1cVsFg7t4Hsyw@mail.gmail.com>
References: <CAH2-Wz==4+OuyyT41md6u3QgJ89RRPMYzAiMGY9vy8Y+E-Lbdg@mail.gmail.com>
<20180416174817.3krcrdtfkiwkhj4s@alvherre.pgsql>
<CAH2-Wz=RDFQAqczdFezYCuyEHid4eHe6e5uEu1cVsFg7t4Hsyw@mail.gmail.com>
Hello, Peter.
Pgpool used only from App side at another server.
Zabbix running its queries directly at database server.
16.04.2018, 21:03, "Peter Geoghegan" <pg@bowt.ie>:
> On Mon, Apr 16, 2018 at 10:48 AM, Alvaro Herrera
> <alvherre@alvh.no-ip.org> wrote:
>> and tuplestore_end does this:
>> if (state->myfile)
>> BufFileClose(state->myfile);
>> without setting anything in state to NULL; so we're relying on the
>> caller fs->tstore to null to avoid repeated tuplestore_end calls. I
>> can't see any way for this to misbehave, but maybe the funcstate appears
>> more than once in the PerFuncState array, and we clean it correctly the
>> first time around and then invoke the tuplestore_end() the second time
>> to the memory that was previously freed? I think this makes no sense
>> unless we share FunctionScanPerFuncState elements -- do we?
>
> I have no reason to think that we do. Offhand, I find it more likely
> that some executor slot that imagines that it owns the tuple frees the
> tuple once, which is followed by a call to tuplestore_end() that frees
> the same tuple a second time (a double-free). As I mentioned, we've
> seen several bugs of that general variety in both tuplestore and
> tuplesort in the past. Some of these have been very subtle.
>
> Note that pgpool is involved here. I don't know much about pgpool, and
> maybe that's totally irrelevant.
>
> --
> Peter Geoghegan
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 from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-bugs@postgresql.org
Cc: wizard_1024@tut.by, pg@bowt.ie, alvherre@alvh.no-ip.org, andres@anarazel.de
Subject: Re: BUG #15144: *** glibc detected *** postgres: postgres smsconsole [local] SELECT: double free or corruption (!pre
In-Reply-To: <2139451523901937@web24o.yandex.ru>
References: <CAH2-Wz==4+OuyyT41md6u3QgJ89RRPMYzAiMGY9vy8Y+E-Lbdg@mail.gmail.com> <20180416174817.3krcrdtfkiwkhj4s@alvherre.pgsql> <CAH2-Wz=RDFQAqczdFezYCuyEHid4eHe6e5uEu1cVsFg7t4Hsyw@mail.gmail.com> <2139451523901937@web24o.yandex.ru>
* 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