Received: from maia.hub.org (maia-5.hub.org [200.46.204.29]) by mail.postgresql.org (Postfix) with ESMTP id 1EBF51337BFB for ; Thu, 12 May 2011 00:36:28 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.29]) (amavisd-maia, port 10024) with ESMTP id 91632-07 for ; Thu, 12 May 2011 03:36:20 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-yx0-f174.google.com (mail-yx0-f174.google.com [209.85.213.174]) by mail.postgresql.org (Postfix) with ESMTP id 8E7D31337BE4 for ; Thu, 12 May 2011 00:36:20 -0300 (ADT) Received: by yxs7 with SMTP id 7so402363yxs.19 for ; Wed, 11 May 2011 20:36:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=SED7ImchjE1vbRnRVMY94z/UuxTqmTj+YKeJgeELu14=; b=SOV8R/BX7tmn2o3ErMAj0b0fOY7zVZl8za9DwKVnF8xQRrS14B0PdOWJj+/XBF5/tq GIuEPelkvXEkf4ajgcNWiMRToZVfbdJPC+QSws6JhavoGhYPjE0/hPoxFsi2eeOmUFfy qXXXDk4Pu13EHOD3beJj7Avzt5SwqLvrzHv3Q= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=mFJ4quvn4Pg0CaNU+vC9PJQ7YtAW6AEd5CSAMT/HyO5twn7wefDqtwCgEoNBtK3nG6 +BO//Uk58vC8QXcU19ALsXWnHwL0avqF2J8p4vIKqhvUnmGozqatKb0yjcX+hVw4h38d K66oOkoB5ybpu20WTLzbb2qF2VxFm2YEqZ/qs= MIME-Version: 1.0 Received: by 10.236.108.177 with SMTP id q37mr12310497yhg.14.1305171379516; Wed, 11 May 2011 20:36:19 -0700 (PDT) Received: by 10.236.103.10 with HTTP; Wed, 11 May 2011 20:36:19 -0700 (PDT) In-Reply-To: <1303464095907-4332601.post@n5.nabble.com> References: <1303464095907-4332601.post@n5.nabble.com> Date: Wed, 11 May 2011 23:36:19 -0400 Message-ID: Subject: Re: Checkpoint execution overrun impact? From: Robert Haas To: drvillo Cc: pgsql-performance@postgresql.org Content-Type: text/plain; charset=ISO-8859-1 X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.898 tagged_above=-10 required=5 tests=BAYES_00=-1.9, FREEMAIL_FROM=0.001, RFC_ABUSE_POST=0.001 X-Spam-Level: X-Archive-Number: 201105/169 X-Sequence-Number: 43678 On Fri, Apr 22, 2011 at 5:21 AM, drvillo wrote: > -given the configuration attached (which is basically a vanilla one) and the > number of buffers written at each execution, are these execution times > normal or above average? They seem fine. Remember that the write is deliberately spread out; it's not as if the system couldn't write out 130-160 8k blocks in less than 30 s. > -in the case of the execution that overruns past the timeout, what are the > implications wrt the client application? Not sure what you are referring to here. > -AFAIU client connections are basically stalled during checkpoints. Is it > reasonable to infer that the fact that the application blocking on a > getConnection() might be related to checkpoints being executed? > -considering some tuning on the PG side, should I try increasing > checkpoint_timeout and rising checkpoint_completion_target to lessen the > impact of IO on the client or should I shorten the period so there's less > stuff to write? from the number of buffers written on average I'd assume the > first option is the one to go for but I might miss some bit of reasoning > here... I'm a bit puzzled by all of this because the logs you posted seem to reflect a system under very light load. Each checkpoint is writing no more than 4% of shared_buffers and the sync phases are generally completing in less than one second. I don't see why that would be causing stalls. -- Robert Haas EnterpriseDB: http://www.enterprisedb.com The Enterprise PostgreSQL Company