X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 5A2AF52A23 for ; Fri, 29 Jul 2005 13:46:20 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 88356-01 for ; Fri, 29 Jul 2005 16:46:17 +0000 (GMT) Received: from davinci.ethosmedia.com (server227.ethosmedia.com [209.128.84.227]) by svr1.postgresql.org (Postfix) with ESMTP id 654D8529F3 for ; Fri, 29 Jul 2005 13:46:11 -0300 (ADT) X-EthosMedia-Virus-Scanned: no infections found Received: from [63.195.55.98] (account josh@agliodbs.com HELO spooky) by davinci.ethosmedia.com (CommuniGate Pro SMTP 4.1.8) with ESMTP id 7670117; Fri, 29 Jul 2005 09:48:24 -0700 From: Josh Berkus Organization: Aglio Database Solutions To: pgsql-performance@postgresql.org Subject: Re: Performance problems testing with Spamassassin Date: Fri, 29 Jul 2005 09:47:03 -0700 User-Agent: KMail/1.8 Cc: "Luke Lonergan" , "Andrew McMillan" , "Matthew Schumacher" References: <3E37B936B592014B978C4415F90D662D0C4221@MI8NYCMAIL06.Mi8.com> In-Reply-To: <3E37B936B592014B978C4415F90D662D0C4221@MI8NYCMAIL06.Mi8.com> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200507290947.03700.josh@agliodbs.com> X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.012 tagged_above=0 required=5 tests=AWL X-Spam-Level: X-Archive-Number: 200507/472 X-Sequence-Number: 13713 Luke, > work_mem = 131072 # min 64, size in KB Incidentally, this is much too high for an OLTP application, although I don't think this would have affected the test. > shared_buffers = 16000 # min 16, at least max_connections*2, 8KB > each checkpoint_segments = 128 # in logfile segments, min 1, 16MB > each effective_cache_size = 750000 # typically 8KB each > fsync=false # turns forced synchronization on or off Try changing: wal_buffers = 256 and try Bruce's stop full_page_writes patch. > I guess we see the real culprit here. Anyone surprised it's the WAL? Nope. On high-end OLTP stuff, it's crucial that the WAL have its own dedicated disk resource. Also, running a complex stored procedure for each and every word in each e-mail is rather deadly ... with the e-mail traffic our server at Globix receives, for example, that would amount to running it about 1,000 times a minute. It would be far better to batch this, somehow, maybe using temp tables. -- Josh Berkus Aglio Database Solutions San Francisco