pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Guillaume Lelarge <guillaume@lelarge.info>
To: Campbell, Lance <lance@illinois.edu>
Cc: Greg Smith <greg@2ndquadrant.com>
Cc: pgsql-performance@postgresql.org
Subject: Re: How much memory is PostgreSQL using
Date: Sat, 03 Apr 2010 13:58:35 +0200
Message-ID: <4BB72D6B.7080009@lelarge.info> (raw)
In-Reply-To: <B10E6810AC2A2F4EA7550D072CDE876004B2E249@SAB-FENWICK.sab.uiuc.edu>
References: <B10E6810AC2A2F4EA7550D072CDE876004B2E218@SAB-FENWICK.sab.uiuc.edu>
	<4BB0DB0D.80208@2ndquadrant.com>
	<B10E6810AC2A2F4EA7550D072CDE876004B2E249@SAB-FENWICK.sab.uiuc.edu>

Le 02/04/2010 22:10, Campbell, Lance a écrit :
> Greg,
> Thanks for your help.
> 
> 1) How does the number of buffers provided by pg_buffercache compare to
> memory (buffers * X = Y meg)?  

1 buffer is 8 KB.

> 2) Is there a way to tell how many total buffers I have available/max?

With pg_buffercache, yes.

SELECT count(*)
FROM pg_buffercache
WHERE relfilenode IS NOT NULL;

should give you the number of non-empty buffers.


-- 
Guillaume.
 http://www.postgresqlfr.org
 http://dalibo.com



view thread (4+ messages)

Message-ID: <4BB72D6B.7080009@lelarge.info>
Permalink:  ../4BB72D6B.7080009@lelarge.info/
Also on:    postgresql.org/message-id/4BB72D6B.7080009@lelarge.info

 · 

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-performance@postgresql.org
  Cc: guillaume@lelarge.info, lance@illinois.edu, greg@2ndquadrant.com
  Subject: Re: How much memory is PostgreSQL using
  In-Reply-To: <4BB72D6B.7080009@lelarge.info>

* 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