Re: cache - timing

From: Vivek Khera <vivek(at)khera(dot)org>
To: PGSQL General <pgsql-general(at)postgresql(dot)org>
Subject: Re: cache - timing
Date: 2007-03-20 14:49:39
Message-ID: BA65C15F-6C60-4607-A3D2-D2C0B14F9B24@khera.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general


On Mar 19, 2007, at 1:58 AM, ab wrote:

> I am trying to measure the time taken for a number of queries using
> \timing .
> All queries on my table other than the first one are pretty fast. This
> is likely due to caching. Is there any way to clear the internal cache
> of Postgres. Should I be worried about the entire OS cache also?

restarting postgres ought to do it.

however, also note that your OS's disk cache plays a big role, and
generally the only way to flush that is to reboot and/or do a lot of
other random IO.

In response to

Browse pgsql-general by date

  From Date Subject
Next Message filippo 2007-03-20 14:58:05 shell script to SQL statement: `pg_dump | psql -U`
Previous Message Dmitry Koterov 2007-03-20 14:47:55 Re: Planner tuning