From: Tom Lane <tgl@sss.pgh.pa.us>
To: havasvolgyi.otto@gmail.com
Cc: pgsql-bugs@postgresql.org
Subject: Re: BUG #6365: Memory leak in insert and update
Date: Thu, 29 Dec 2011 15:10:17 -0500
Message-ID: <27188.1325189417@sss.pgh.pa.us> (raw)
In-Reply-To: <E1RgM1U-0002Z1-Em@wrigleys.postgresql.org>
References: <E1RgM1U-0002Z1-Em@wrigleys.postgresql.org>
havasvolgyi.otto@gmail.com writes:
> The following bug has been logged on the website:
> Bug reference: 6365
> Logged by: Otto Havasvölgyi
> Email address: havasvolgyi.otto@gmail.com
> PostgreSQL version: 9.1.2
> Operating system: Win XP SP2 x86; Linux Debian 2.6.32 kernel x64
> Description:
> The bug can be reproduced with pgbench:
I see no memory leak with this example.
I suspect you are being fooled by tools that report shared memory as
being used by a process only after it first touches a given page of
shared memory ("top" on Linux does that, for example). This will cause
the apparent memory consumption of any long-lived backend to increase
until it has touched every available shared buffer. But that's not a
leak, just an artifact of the reporting tool. You can confirm for
yourself that that's what's happening by reducing shared_buffers to
a few megabytes and observing that reported memory usage increases up
to that much and then stops growing.
On Linux, I find that watching the "VIRT" column of top output is a
far more reliable guide to whether a memory leak is actually occuring.
Can't offer any suggestions as to what to use on Windows.
regards, tom lane
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: tgl@sss.pgh.pa.us, havasvolgyi.otto@gmail.com
Subject: Re: BUG #6365: Memory leak in insert and update
In-Reply-To: <27188.1325189417@sss.pgh.pa.us>
References: <E1RgM1U-0002Z1-Em@wrigleys.postgresql.org> <27188.1325189417@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