Received: from maia.hub.org (unknown [200.46.208.211]) by mail.postgresql.org (Postfix) with ESMTP id 06A786337DE for ; Fri, 16 Apr 2010 15:36:31 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.208.211]) (amavisd-maia, port 10024) with ESMTP id 44647-07 for ; Fri, 16 Apr 2010 18:36:17 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-qy0-f201.google.com (mail-qy0-f201.google.com [209.85.221.201]) by mail.postgresql.org (Postfix) with ESMTP id 2D9D963358A for ; Fri, 16 Apr 2010 15:36:20 -0300 (ADT) Received: by qyk39 with SMTP id 39so3367499qyk.24 for ; Fri, 16 Apr 2010 11:36:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :from:date:received:message-id:subject:to:cc:content-type :content-transfer-encoding; bh=Bqp7HR/K36OyR2vShdehYsAZRlbPWZWO0r4j/vcsRd8=; b=oEvDnS2zcS3nYPlKoviY0MqfCIZ+3KbdEfIgtrAzypWijIeyMs7DY+4VaeSmR58hRR Sws448LZ+RI1E+4d99hQTnxsqj5AY+/9jK8PBc6U5WtfvpJe5Yk1xkYyoGHEksQno9ji 7pMet8VBr/0q5WHl3JC2eF/Fp+Kx1GvRoFUWw= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type:content-transfer-encoding; b=nrEUR2qPwxlKt44K4QsJkEVEl53KFAiizJPgShZC0hneWWog47U4f1JTO6Zw4deDke G6MNhOnXaB/hEveGaghxiZv+WQVg9O53oEMLanECYb5LnlGTk80dHOtgK6cTID9DWWfq LA4QaxZMe8A2vvjB4BoXlglRCkkprjTK2jpSA= MIME-Version: 1.0 Received: by 10.229.88.3 with HTTP; Fri, 16 Apr 2010 11:35:56 -0700 (PDT) In-Reply-To: <4BC8A91D.9030709@2ndquadrant.com> References: <20100413170105.GA29571@chris-laptop.a2hosting.com> <25952.1271370711@sss.pgh.pa.us> <9738.1271431432@sss.pgh.pa.us> <10082.1271432484@sss.pgh.pa.us> <11152.1271436528@sss.pgh.pa.us> <4BC8A91D.9030709@2ndquadrant.com> From: Josh Kupershmidt Date: Fri, 16 Apr 2010 14:35:56 -0400 Received: by 10.229.26.135 with SMTP id e7mr2071316qcc.58.1271442976338; Fri, 16 Apr 2010 11:36:16 -0700 (PDT) Message-ID: Subject: Re: stats collector suddenly causing lots of IO To: Greg Smith Cc: Tom Lane , Chris , pgsql-performance@postgresql.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-2.023 tagged_above=-10 required=5 tests=AWL=-0.123, BAYES_00=-1.9 X-Spam-Level: X-Archive-Number: 201004/223 X-Sequence-Number: 38473 On Fri, Apr 16, 2010 at 2:14 PM, Greg Smith wrote: > Josh Kupershmidt wrote: >> >> SELECT name, current_setting(name), source FROM pg_settings WHERE >> source !=3D 'default' AND name ILIKE '%vacuum%'; >> =A0 =A0 =A0 =A0 name =A0 =A0 =A0 =A0 | current_setting | =A0 =A0 =A0 sou= rce >> ----------------------+-----------------+-------------------- >> =A0vacuum_cost_delay =A0 =A0| 200ms =A0 =A0 =A0 =A0 =A0 | configuration = file >> =A0vacuum_cost_limit =A0 =A0| 100 =A0 =A0 =A0 =A0 =A0 =A0 | configuratio= n file >> =A0vacuum_cost_page_hit | 6 =A0 =A0 =A0 =A0 =A0 =A0 =A0 | configuration = file >> >> =A0Hopefully changing those three vacuum_cost_* params will speed up the >> manual- and auto-vacuums.. > > Those only impact manual VACUUM statements. =A0There's a different set wi= th > names like autovacuum_vacuum_cost_delay that control the daemon. =A0You c= an > set those to "-1" in order to match the regular VACUUM, but that's not th= e > default. It looks like the default which I have of autovacuum_vacuum_cost_limit =3D -1, which means it's inheriting the vacuum_cost_limit of 100 I had set. I'll try bumping vacuum_cost_limit up to 1000 or so. > You really need to sort out the max_fsm_pages setting too, because until > that issue goes away these tables are unlikely to ever stop growing. =A0A= nd, > no, you can't use CLUSTER on the system tables to clean those up. I have max_fsm_pages =3D 524288 , but from the hints in the logfiles this obviously needs to go up much higher. And it seems the only way to compact the pg_catalog tables is VACUUM FULL + REINDEX on 8.3 -- I had tried the CLUSTER on my 9.0 machine and wrongly assumed it would work on 8.3, too. Josh