From: Tom Lane <tgl@sss.pgh.pa.us>
To: Radoslaw Stachowiak <radek@alter.pl>
Cc: pgsql-admin@postgresql.org
Subject: Re: strange inefficiency in shared memory handling
Date: Thu, 30 May 2002 18:04:58 -0400
Message-ID: <8084.1022796298@sss.pgh.pa.us> (raw)
In-Reply-To: <20020530205101.GC7410@blue.alter.pl>
References: <20020530205101.GC7410@blue.alter.pl>
Radoslaw Stachowiak <radek@alter.pl> writes:
> of course this memory removal of cached index blocks is caused by normal
> queries and their memory (buffer) requirements, but certainly algorithm
> which chose which buffer to remove is a very ineffective on index blocks.
> looks to me that it preffer table-block too much (especially compared
> to index ones)
The buffer management code has absolutely no clue which blocks belong
to indexes and which to tables --- it handles all of them on a uniform
LRU basis.
> with buffers <1000 idx_blks_hit was always smaller than idx_blks_read,
> even by 10 times;
> statio_user_tables showed that hits were larger than reads by
> _great_ amount (factor of 2 and more) - so it shows that shared_buffers
> are used very well on tables but not on indexes :-(
This seems odd, but I wonder whether it is an artifact of some unusual
property of your query workload. You haven't offered enough detail to
let someone else try to reproduce it...
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-admin@postgresql.org
Cc: tgl@sss.pgh.pa.us, radek@alter.pl
Subject: Re: strange inefficiency in shared memory handling
In-Reply-To: <8084.1022796298@sss.pgh.pa.us>
References: <20020530205101.GC7410@blue.alter.pl> <8084.1022796298@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