Re: Slow count(*) again...

Greg Smith <greg@2ndquadrant.com>

From: Greg Smith <greg@2ndquadrant.com>
To: Jon Nelson <jnelson+pgsql@jamponi.net>
Cc: mladen.gogala@vmsinfo.com, "david@lang.hm" <david@lang.hm>, Craig Ringer <craig@postnewspapers.com.au>, Vitalii Tymchyshyn <tivv00@gmail.com>, "pgsql-performance@postgresql.org" <pgsql-performance@postgresql.org>
Date: 2010-10-12T13:18:34Z
Lists: pgsql-hackers, pgsql-performance
Jon Nelson wrote:
> Is there a command to tell postgresql to drop/clear/reset it's buffer_cache?
>   

No.  Usually the sequence used to remove all cached data from RAM before 
a benchmark is:

pg_ctl stop
sync
echo 3 > /proc/sys/vm/drop_caches
pg_ctl start

-- 
Greg Smith, 2ndQuadrant US greg@2ndQuadrant.com Baltimore, MD
PostgreSQL Training, Services and Support  www.2ndQuadrant.us
Author, "PostgreSQL 9.0 High Performance"    Pre-ordering at:
https://www.packtpub.com/postgresql-9-0-high-performance/book