Re: [PERFORM] Memory question on win32 systems

From: "Merlin Moncure" <mmoncure(at)gmail(dot)com>
To: Justin <justin(at)emproshunts(dot)com>
Cc: Sabbiolina <sabbiolina(at)gmail(dot)com>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: [PERFORM] Memory question on win32 systems
Date: 2008-05-29 14:33:53
Message-ID: b42b73150805290733y2d10b74ena234b3f276d19752@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Thu, May 29, 2008 at 10:19 AM, Justin <justin(at)emproshunts(dot)com> wrote:
> To my understanding Postgresql only caches queries and results in memory for
> that specific connection. So when that connection is closed those cached
> results are cleared out. So cached indexs and queries are for that
> connection only. I hope my understanding is correct.

completely wrong.

They are called 'shared' buffers for a reason. Also you are missing
the point of the o/s file cache which lies under that. If you have a
computer with 4gb ram that is addressable, all its memory is used for
caching at all times, period, less what operating system needs or what
is used by running programs or temporary demands (sorting, etc).

Also, postgresql doesn't as a rule cache 'results and queries'.

shared buffers setting reserves memory for postgresql's internal cache
(plus some housekeeping things like locks)...which can be faster than
the o/s cache because it is more tightly integrated with the backend.
However a page fault to disk is much more interesting in performance
terms than the performance differences between shared buffers and o/s
cache.

merlin

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 2008-05-29 14:41:08 Re: [HACKERS] Upcoming back-branch update releases
Previous Message Martijn van Oosterhout 2008-05-29 14:30:53 Re: [PERFORM] Memory question on win32 systems