Skip site navigation (1) Skip section navigation (2)

Re: database caches

From: Neil Conway <neilc(at)samurai(dot)com>
To: Ruslan A Dautkhanov <rusland(at)scn(dot)ru>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: database caches
Date: 2002-10-29 05:27:18
Message-ID: 87d6pt3jd5.fsf@mailbox.samurai.com (view raw or flat)
Thread:
Lists: pgsql-bugs
Ruslan A Dautkhanov <rusland(at)scn(dot)ru> writes:
>     I have problem in PG performance - all database caches is allocated
>     to one table, which is much greater than all other tables together, but
>     requests to this huge table much rarely, than requests with
>     other tables.

What makes you think that all the cache is allocated for this one
specific table?

Also, caching is done on a page-by-page basis, not per-relation.

>     How can I adjust which tables should be cached more (cache rate), and
>     which less, if this possible?? Or which tables not to cache
>     completely.

The buffer manager decides what to cache by itself; there are a few
knobs you can tweak (shared_buffers, for example), but for the most
part the buffer manager is expected to do its job.

In your specific example, it doesn't sound like there's a need to
manually tweak the buffer manager: the large but infrequently accessed
table will likely not have very many buffers kept in memory.

Cheers,

Neil

-- 
Neil Conway <neilc(at)samurai(dot)com> || PGP Key ID: DB3C29FC


In response to

pgsql-bugs by date

Next:From: Vincent LimDate: 2002-10-29 07:44:12
Subject: Re: Postgresql 7.2.3
Previous:From: Ruslan A DautkhanovDate: 2002-10-29 04:25:51
Subject: database caches

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group