X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by postgresql.org (Postfix) with ESMTP id 64B379DCA20 for ; Wed, 1 Feb 2006 13:42:28 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 96697-02 for ; Wed, 1 Feb 2006 13:42:27 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey- Received: from mail.Mi8.com (d01gw01.mi8.com [63.240.6.47]) by postgresql.org (Postfix) with ESMTP id 061A09DC949 for ; Wed, 1 Feb 2006 13:42:25 -0400 (AST) Received: from 172.16.1.25 by mail.Mi8.com with ESMTP (- Welcome to Mi8 Corporation www.Mi8.com (D1)); Wed, 01 Feb 2006 12:42:16 -0500 X-Server-Uuid: 241911D6-425B-44B9-A073-E3FE0F8FC774 Received: from MI8NYCMAIL06.Mi8.com ([172.16.1.175]) by D01HOST03.Mi8.com with Microsoft SMTPSVC(6.0.3790.1830); Wed, 1 Feb 2006 12:42:15 -0500 Received: from 67.103.45.218 ([67.103.45.218]) by MI8NYCMAIL06.Mi8.com ( [172.16.1.219]) via Exchange Front-End Server mi8owa.mi8.com ( [172.16.1.106]) with Microsoft Exchange Server HTTP-DAV ; Wed, 1 Feb 2006 17:42:14 +0000 User-Agent: Microsoft-Entourage/11.2.1.051004 Date: Wed, 01 Feb 2006 09:42:12 -0800 Subject: Re: Huge Data sets, simple queries From: "Luke Lonergan" To: "PFC" , "Jeffrey W. Baker" cc: pgsql-performance@postgresql.org Message-ID: Thread-Topic: [PERFORM] Huge Data sets, simple queries Thread-Index: AcYnDgi8W6A/b6ncQWWiAoo3F5S6bAASMw0g In-Reply-To: MIME-Version: 1.0 X-OriginalArrivalTime: 01 Feb 2006 17:42:15.0259 (UTC) FILETIME=[D6E43AB0:01C62756] X-WSS-ID: 6FFE2D7D32K2442867-02-01 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, score=1.318 required=5 tests=[AWL=0.065, RCVD_NUMERIC_HELO=1.253] X-Spam-Score: 1.318 X-Spam-Level: * X-Archive-Number: 200602/16 X-Sequence-Number: 17002 PFC, On 2/1/06 1:01 AM, "PFC" wrote: > 3- Read one block of A, then one block of B, then one block of A, etc. > Essentially this is the same as the threaded case, except there's only one > thread. > 53 seconds total (with heavy seeking noise from the hdd). > > I was half expecting 3 to take the same as 2. It simulates, for > instance, > scanning a table and its index, or scanning 2 sort bins. Well, maybe one > day... This is actually interesting overall - I think what this might be showing is that the Linux SW RAID1 is alternating I/Os to the mirror disks from different processes (LWP or HWP both maybe?), but not within one process. > It would be nice if the Kernel had an API for applications to tell it > "I'm gonna need these blocks in the next seconds, can you read them in the > order you like (fastest), from whatever disk you like, and cache them for > me please; so that I can read them in the order I like, but very fast ?" More control is always good IMO, but for now there's I/O reordering in the SCSI layer and readahead tuning. There is POSIX fadvise() also to tell the underlying I/O layer what the access pattern looks like. - Luke