Received: from maia.hub.org (maia-3.hub.org [200.46.204.243]) by mail.postgresql.org (Postfix) with ESMTP id E863BB5D944 for ; Wed, 13 Jul 2011 12:17:48 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.243]) (amavisd-maia, port 10024) with ESMTP id 00889-05 for ; Wed, 13 Jul 2011 15:17:42 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from sss.pgh.pa.us (sss.pgh.pa.us [66.207.139.130]) by mail.postgresql.org (Postfix) with ESMTP id AAF05B5DCCD for ; Wed, 13 Jul 2011 12:17:42 -0300 (ADT) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.2/8.14.2) with ESMTP id p6DFHfGJ004753; Wed, 13 Jul 2011 11:17:41 -0400 (EDT) To: "Kevin Grittner" cc: "lars" , "Ivan Voras" , pgsql-performance@postgresql.org Subject: Re: UPDATEDs slowing SELECTs in a fully cached database In-reply-to: <4E1D697C020000250003F29A@gw.wicourts.gov> References: <4E16479D.3050605@yahoo.com> <4E1A0CBC.6090009@yahoo.com> <4E1A31AB.9010201@postnewspapers.com.au> <1310359653.80687.YahooMailRC@web121705.mail.ne1.yahoo.com> <4E1AEDAB020000250003F1C3@gw.wicourts.gov> <4E1B41EA.90104@yahoo.com> <4E1B05CC020000250003F1E6@gw.wicourts.gov> <4E1B810D.4070404@yahoo.com> <4E1B90AF.1020408@yahoo.com> <4E1C9A05.7060005@yahoo.com> <4E1C5563020000250003F252@gw.wicourts.gov> <4E1CA8E9.6090108@yahoo.com> <4E1CB56E.7080801@yahoo.com> <4E1D697C020000250003F29A@gw.wicourts.gov> Comments: In-reply-to "Kevin Grittner" message dated "Wed, 13 Jul 2011 09:46:36 -0500" Date: Wed, 13 Jul 2011 11:17:41 -0400 Message-ID: <4752.1310570261@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.91 tagged_above=-10 required=5 tests=BAYES_00=-1.9, T_RP_MATCHES_RCVD=-0.01 X-Spam-Level: X-Archive-Number: 201107/136 X-Sequence-Number: 44348 "Kevin Grittner" writes: > ... Jeff does raise a good point, though -- it seems odd > that WAL-logging of this pruning would need to be synchronous. Yeah, we need to get to the bottom of that. If there's enough shared_buffer space then it shouldn't be. > We > support asynchronous commits -- why not use that feature > automatically for transactions where the only writes are this sort > of thing. Which raises an interesting question -- what happens to > the timings if your SELECTs are done with synchronous_commit = off? > I wonder if it would make any sense to implicitly use async commit > for a transaction which is declared READ ONLY or which never > acquires and XID? Huh? If there was never an XID, there's no commit WAL record, hence nothing to make asynchronous. regards, tom lane