Re: Out of memory error

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Chris Roberts <croberts(at)rossvideo(dot)com>
Cc: "pgsql-general(at)postgresql(dot)org" <pgsql-general(at)postgresql(dot)org>
Subject: Re: Out of memory error
Date: 2016-12-09 20:49:44
Message-ID: 30524.1481316584@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Chris Roberts <croberts(at)rossvideo(dot)com> writes:
> Would someone tell me why I am seeing the following Postgres logs?

> 07:56:20 EST LOG: 08P00: incomplete message from client
> 07:56:20 EST LOCATION: pq_getmessage, src\backend\libpq\pqcomm.c:1143
> 07:56:20 EST ERROR: 54000: out of memory
> 07:56:20 EST DETAIL: Cannot enlarge string buffer containing 0 bytes by 1157627900 more bytes.
> 07:56:20 EST LOCATION: enlargeStringInfo, src\backend\lib\stringinfo.c:268

What that looks like is corrupt data coming in from the connected client;
either the client has actually sent something wrong, or the server has
somehow gotten out of sync as to where the message boundaries are in
the data stream. One way or the other it's interpreting some bytes as
a message length word when they aren't a valid length.

9.3.5 is kind of old, so rather than trying to chase down exactly where
things are going wrong, I suggest you update to 9.3.latest and see if
the problem is still there. Also look at whether there are newer versions
of whatever client-side libraries you're using, since there's at least
a 50-50 chance that the bug is on that side not the server.

(I'm a bit suspicious that this might be related to commit 2b3a8b20c,
which went into 9.3.6, but it's probably premature to blame that.)

regards, tom lane

In response to

Browse pgsql-general by date

  From Date Subject
Next Message John R Pierce 2016-12-09 21:08:45 Re: Regrding:- Arduino-Postgresql Direct Connection
Previous Message Raymond O'Donnell 2016-12-09 17:59:05 Re: Multidimentional array access