Received: from malur.postgresql.org ([2a02:16a8:dc51::56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1g78IL-0005xx-87 for pgsql-hackers@arkaria.postgresql.org; Tue, 02 Oct 2018 00:12:09 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1g78II-0004zw-4K for pgsql-hackers@arkaria.postgresql.org; Tue, 02 Oct 2018 00:12:06 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1g78IH-0004zp-TK for pgsql-hackers@lists.postgresql.org; Tue, 02 Oct 2018 00:12:05 +0000 Received: from out3-smtp.messagingengine.com ([66.111.4.27]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1g78IB-0005Ex-Ro for pgsql-hackers@lists.postgresql.org; Tue, 02 Oct 2018 00:12:05 +0000 Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailout.nyi.internal (Postfix) with ESMTP id A18AA218EB; Mon, 1 Oct 2018 20:11:58 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute4.internal (MEProxy); Mon, 01 Oct 2018 20:11:58 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=paquier.xyz; h= cc:content-type:date:from:in-reply-to:message-id:mime-version :references:subject:to:x-me-sender:x-me-sender:x-sasl-enc; s= fm2; bh=PnCRV7y0evVV//gpPnflKqWZLvZGpTvn98B7UfVhF6Y=; b=iqLIH8qM CqZj2uP4Qrv2cTdXVLWHRuHACX5qNTJL71e24zP9J4TvqNO1HdhUPqrbgHUpVXF+ Mz7Ure10Onn+ttJ0jgKzlFtIMoUXpm+EI0hwhlcTrhluHAgg6d2S/eXOv/qFDD1c iB7Qd2BdO5CcUqcb9rbxkzN6r8r4r3wIwZvGY8zgh5w2CkAcr9DrUfST66zq47Sg dd4fDQH2rykogacH/ZEPTcBx7kyd157rc7N4VPLkdaJpiWzXT2iQAMTqsA5Q57r6 J7146yqD5fXtafH493NM6xcHS9T2eWIirhNYWrf2azoyiZspjZwyo1TjOBhsN6N1 7l0Jw1YYd2t9QQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-sender :x-me-sender:x-sasl-enc; s=fm3; bh=PnCRV7y0evVV//gpPnflKqWZLvZGp Tvn98B7UfVhF6Y=; b=l/k+GvLobILb1nlddmUWTDZLtw1EzMlZBQdwh+D5UiCRu H9dkbfz5svCL5/XS92CBZET43Q7sAC6JrD1+Y1dsVwi8WRoICiGRGjfTIn1xHLoN RwXf3myU6qiUJkvlM1KFEWsLC6hp/SAy4gsPoONhIdYfo85M1SNt4FhRi9Mx9jZw GVPff0qcup0t7AB+jagAwIq++7lsQqjgPXA0G3iaasWAJEBIunxO9QcK/W6Y1Z/Q UpCOt8eRNd31kz6ykyeAug3uXpsZdmP5ZCk3LEdTx4N8C/8l67TbluX8l2IMA68G a4hD6tFVi8zfYf1vsAABy/T5dzyzwSxw9sdfAJELw== X-ME-Sender: X-ME-Proxy: Received: from paquier.xyz (c137162.net61215.cablenet.ne.jp [61.215.137.162]) by mail.messagingengine.com (Postfix) with ESMTPA id BC725102DE; Mon, 1 Oct 2018 20:11:54 -0400 (EDT) Date: Tue, 2 Oct 2018 09:11:51 +0900 From: Michael Paquier To: Masahiko Sawada Cc: Alvaro Herrera , Sergei Kornilov , nasbyj@amazon.com, Andres Freund , Robert Haas , PostgreSQL Hackers Subject: Re: pgsql: Improve autovacuum logging for aggressive and anti-wraparound ru Message-ID: <20181002001151.GP11712@paquier.xyz> References: <23209391537822541@iva4-6d7004ac8463.qloud-c.yandex.net> <20180924211117.tpwxemzd3372nagj@alvherre.pgsql> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="pleSNuEbvnUYtMxG" Content-Disposition: inline In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk --pleSNuEbvnUYtMxG Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Fri, Sep 28, 2018 at 01:53:14PM +0900, Masahiko Sawada wrote: > I agree. Can we fix this simply by the attached patch? Thanks for sending a patch. + /* autovacuum cannot be anti-wraparound and not aggressive vacuum */ + Assert(aggressive); + msgfmt = _("automatic aggressive vacuum to prevent wraparound of table \"%s.%s.%s\": index scans: %d\n"); While adding this comment in lazy_vacuum_rel() is adapted, I think that we ought to make the assertion check more aggressive by not having it depend on if log_min_duration is set or not. So why not moving that to a place a bit higher, where aggressive gets defined? -- Michael --pleSNuEbvnUYtMxG Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEG72nH6vTowiyblFKnvQgOdbyQH0FAluyt8cACgkQnvQgOdby QH18MA//RDWjgq6OjYGIElOfI1t3f2Xoiy5HqdK+8VMnzqBKeVranvKTPnimLIDi uQjcuYHzKY8jitZ39W09c41WYUMDN0ZnzUo64vn+ulIsO2gRNMqqbbl5q4IAZhM3 0mJc1v5avpCRnbrvYvS2M2pDOVEcLDeKrkYhTuOjLystogRsAja5b1NxfqVJ0igK 95IDFK0TonMAZHqDEQGWa4hrbuest4OfViyaxD4Q1J3DDPxancJDEJ8R7eqXVATw E+9YnezGwdh+4+fLiRFYFCkOu8zYl69dxaoyB2OW/hz+t5IvXTfgJ3BddRZ8GGmw ya6J9pMuA4P5qD86dsRcV0lIXZGcQ+vcc2rNUCQHWPdDe2MbAWNSjE4ELdU9mUUf qj3pkU8Tema7TbHn6XFPycRudvcjcfqGCUebn2tlkVLtVGzQdkfo0v3DCJiMJyYa qgNZIOHg/nBptCEyz8exdz5irfroNuzEjh77Ov2kGuJbbDPJVs9NzLwgFvcDNygP /N6xoDeYPIr8niKd/D6d3CqrUm40Eb6DdTtvEC4i78B7YJmVW5KjARiHIq4rMg83 WhE3jeXCEbwRfFVKdwCxiZlW+M9tZ6QarPR14uSIkhMHeaRkK4CLQAPHfIU35Xro CnY/KAdUPupHsS208D4MtJgjis74SnJ6QZzOLn5FvG6L92NvxJM= =nSuA -----END PGP SIGNATURE----- --pleSNuEbvnUYtMxG--