Determining random_page_cost value

From: "Yohanes Santoso" <ysantoso(at)gmail(dot)com>
To: pgsql-hackers(at)postgresql(dot)org
Subject: Determining random_page_cost value
Date: 2005-10-25 13:45:12
Message-ID: 1130247912.303864.223580@g44g2000cwa.googlegroups.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

I talked with neilc in #postgresql about a tool that may help in
determining a suitable rpc value. If rpc is just ratio of random cost
vs. sequential cost, then I can write such a tool. So I did.

The tool takes a directory and do sequential read on all the files
there, followed by exhaustive (each block is read) random read on each
file. There is also an option to clear up buffers between runs.

I then ran it on various database size on a software 2 7200RPM IDE
RAID-1 volume. I found out that if the dbase size (as from du
<dbase_dir>) is less than about 500M, I got a ratio of 4.5:1. On a
larger dbase, 3GB, the ratio increases to 10:1.

This tells me that the ratio needs to be qualified further: access over
what size of dbase? access over the disk volume instead? what other
hidden variables?

The full code is at http://rafb.net/paste/results/peLyIX45.html

Thanks,
Gnome.

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 2005-10-25 13:47:52 Re: sort_mem statistics ...
Previous Message Tom Lane 2005-10-25 13:24:04 Re: PG Killed by OOM Condition