Received: from localhost (unknown [200.46.204.182]) by postgresql.org (Postfix) with ESMTP id 73CE52E28AD for ; Wed, 14 Nov 2007 10:58:50 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.182]) (amavisd-maia, port 10024) with ESMTP id 44743-08 for ; Wed, 14 Nov 2007 10:58:40 -0400 (AST) Received: from vms046pub.verizon.net (vms046pub.verizon.net [206.46.252.46]) by postgresql.org (Postfix) with ESMTP id 1AA7C2E1C5B for ; Wed, 14 Nov 2007 10:58:46 -0400 (AST) Received: from [192.168.0.251] ([71.251.196.74]) by vms046.mailsrvcs.net (Sun Java System Messaging Server 6.2-6.01 (built Apr 3 2006)) with ESMTPA id <0JRI0029L49L7Y13@vms046.mailsrvcs.net> for pgsql-performance@postgresql.org; Wed, 14 Nov 2007 08:58:34 -0600 (CST) Date: Wed, 14 Nov 2007 09:58:33 -0500 From: Jean-David Beyer Subject: Re: Curious about dead rows. In-reply-to: <20071114125808.GO19014@alvh.no-ip.org> To: pgsql performance Message-id: <473B0D19.4000509@verizon.net> Organization: Institute for Regimented Whimsey MIME-version: 1.0 Content-type: text/plain; charset=ISO-8859-1 Content-transfer-encoding: 7bit X-Enigmail-Version: 0.94.0.0 References: <4735DBDB.5050208@verizon.net> <16627.1194714491@sss.pgh.pa.us> <4735FA9F.1080805@verizon.net> <473A5CC0.3060003@verizon.net> <473AE63D.7090305@verizon.net> <20071114125808.GO19014@alvh.no-ip.org> User-Agent: Thunderbird 1.5.0.9 (X11/20070317) X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200711/212 X-Sequence-Number: 27627 Alvaro Herrera wrote: > Jean-David Beyer wrote: > >> How do I reset the counters in pg_stat_database and pg_stat_all_tables? >> I tried just restarting postgres, but it seems to be saved in the database, >> not just in the RAM of the server. > > There is a function called pg_stat_reset() or some such. I'll find it. > >> I suppose that blks_read and blks_hit are zero because there are 8 GBytes >> RAM on this machine and I give 2GBytes to shared_buffers = 253000 so that >> all sits in RAM. > > Perhaps you have stats_block_level set to off? True, I will turn them on. > >> I know there have been rollbacks but I do a REINDEX, CLUSTER, and VACUUM >> ANALYZE before starting the inserts in question. > > You do all three on the same tables? That seems pretty pointless. A > sole CLUSTER has the same effect. I was only doing this to be sure to clean everything up for this data gathering process and wanted to know I did not miss anything. > >> Do I need to do a VACUUM FULL ANALYZE instead? > > No. > -- .~. Jean-David Beyer Registered Linux User 85642. /V\ PGP-Key: 9A2FC99A Registered Machine 241939. /( )\ Shrewsbury, New Jersey http://counter.li.org ^^-^^ 09:50:01 up 22 days, 3:08, 4 users, load average: 4.29, 4.17, 4.11