X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (mx2.hub.org [200.46.204.254]) by postgresql.org (Postfix) with ESMTP id C52CF11F662E for ; Wed, 19 Apr 2006 02:13:58 -0300 (ADT) X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Score: -2.386 X-Spam-Level: X-Spam-Status: No, score=-2.386 required=5 tests=[AWL=0.213, BAYES_00=-2.599] Received: from postgresql.org ([200.46.204.71]) by localhost (mx2.hub.org [200.46.204.254]) (amavisd-new, port 10024) with ESMTP id LGJCQkMD6i0G for ; Wed, 19 Apr 2006 02:13:51 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey- Received: from noel.decibel.org (noel.decibel.org [67.100.216.10]) by postgresql.org (Postfix) with ESMTP id C2F1411F61D2 for ; Wed, 19 Apr 2006 02:13:50 -0300 (ADT) Received: by noel.decibel.org (Postfix, from userid 1001) id DE4CF56423; Wed, 19 Apr 2006 00:13:47 -0500 (CDT) Received: (hashcash-sendmail, from uid 1001); Wed, 19 Apr 2006 00:13:47 -0500 Date: Wed, 19 Apr 2006 00:13:47 -0500 From: "Jim C. Nasby" To: Terje Elde Cc: pgsql-performance@postgresql.org Subject: Re: Blocks read for index scans Message-ID: <20060419051346.GQ49405@pervasive.com> References: <85979594-1CCA-43C5-A8F2-08685CF41ACE@pervasive.com> <443F3BB3.30404@elde.net> <20060418200641.GG49405@pervasive.com> <4445A1DF.6000705@elde.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4445A1DF.6000705@elde.net> X-Operating-System: FreeBSD 6.0-RELEASE-p4 amd64 X-Distributed: Join the Effort! http://www.distributed.net User-Agent: Mutt/1.5.11 X-Hashcash: 1:20:060419:terje@elde.net::iXmy7Sd6+SguHEOE:0006DtM X-Hashcash: 1:20:060419:pgsql-performance@postgresql.org::YVPAmjxW3QeRHHJ2:00000 0000000000000000000000000Krv X-Archive-Number: 200604/416 X-Sequence-Number: 18500 On Wed, Apr 19, 2006 at 04:35:11AM +0200, Terje Elde wrote: > Jim C. Nasby wrote: > >>That said, it's the transactions against disk that typically matter. On > >>FreeBSD, you can get an impression of this using 'systat -vmstat', and > >>watch the KB/t column for your drives. > >> > > > >On a related note, you know of any way to determine the breakdown > >between read activity and write activity on FreeBSD? vmstat, systat, > >iostat all only return aggregate info. :( > > > > > Can't think of a right way to do this ATM, but for a lab-type setup to > get an idea, you could set up a gmirror volume, then choose a balancing > algorithm to only read from one of the disks. The effect should be that > writes go to both, while reads only go to one. Activity on the > write-only disk would give you an idea of the write activity, and > (read/write disk - write-only disk) would give you an idea of the > reads. I have to admit though, seems like quite a bit of hassle, and > I'm not sure how good the numbers would be, given that at least some of > the info (KB/transaction) are totals, it'd require a bit of math to get > decent numbers. But at least it's something. Yeah... not gonna happen... It's completely mind-boggling that FBSD doesn't track writes and reads seperately. -- Jim C. Nasby, Sr. Engineering Consultant jnasby@pervasive.com Pervasive Software http://pervasive.com work: 512-231-6117 vcard: http://jim.nasby.net/pervasive.vcf cell: 512-569-9461