Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1n7TFf-00029I-84 for pgsql-hackers@arkaria.postgresql.org; Wed, 12 Jan 2022 02:20:39 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1n7TFd-0005KB-3k for pgsql-hackers@arkaria.postgresql.org; Wed, 12 Jan 2022 02:20:37 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1n7TFc-0005JT-OB for pgsql-hackers@lists.postgresql.org; Wed, 12 Jan 2022 02:20:36 +0000 Received: from mail-io1-xd33.google.com ([2607:f8b0:4864:20::d33]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1n7TFV-0004pU-Pv for pgsql-hackers@lists.postgresql.org; Wed, 12 Jan 2022 02:20:35 +0000 Received: by mail-io1-xd33.google.com with SMTP id v6so1591116iom.6 for ; Tue, 11 Jan 2022 18:20:29 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telsasoft-com.20210112.gappssmtp.com; s=20210112; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=pxSIKf0K9nbzO+abMIUw9T7xbI7MJ+9L0F1jf8zQUsQ=; b=pnFyqQwKmF0+nRWHpVU8jHwdscpnx9md8FUYH79O5F7i3nV4zv3p9f+usyZLNGo3kj jcR/eN8IvvaQ2mx3W4oKFGE7vB4KHid7sXlf8r3x4+XbU1YF7OP15LaBdv0VgJFq7qx1 toh7wkGP0HZBgONl95i0js8PHFrtWEADREKant25stKo4RkN63x5FJF8bzZveT4t6hN6 HP/bDktFs2d3DKv1JETZUyaDYkUq1676ZxKtc/qlgRIpPl41b08ZA2aWdpI8REqGhr9o cXyJn0CqpYbICQmXE7rnpTRU8qjaWqcqCqfiQqkbEhC8bEh3LNyBhSVzLmQUf2G7AwWS 49/A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=pxSIKf0K9nbzO+abMIUw9T7xbI7MJ+9L0F1jf8zQUsQ=; b=YnRDNHfH4rSOaJVx/0Yincn2rGMRj1NGtqaV+SQrLsWCSQRMcHKQqQulb+4TUdGfWA veZTvQCpOjdKxE+9L3RXt1chprG+HcuF971WcM32w0JFDE6FK+6ZdhYDucD0lbk82xhb i1M8UkBTBDWAaGZSevl6xI9zA5MJ4Xhqz+us6Yo7csqPFVpYsFea+fhije0SDjaPVNg7 xSKwGWhcP57yKERINdI2DskK1AyfR2oCYsTHmYR8DAtKvBpZ/1VNSdamaglpuhOpl7YZ ZaH//nvVMJXkh7BEBRh8nVDHOnRF9+fnuET9MFFOdcUGkx+ZOlKvYjZ8tuLsHishzWF5 8BZw== X-Gm-Message-State: AOAM532Gqdeg3qATbNbrMb+of54EbuuedefiV0pKHKPvz/eG8+mPhzAh gR7M1L+D/mb2sMedQhlM7JEByQ== X-Google-Smtp-Source: ABdhPJwKMt+YetIUip9jKAmSFZTGfcvdEB/xAyResFS6z9pnTLODQnx6bq2D3tJXESd34IXx2YjCrQ== X-Received: by 2002:a05:6638:72a:: with SMTP id j10mr3444966jad.187.1641954028504; Tue, 11 Jan 2022 18:20:28 -0800 (PST) Received: from pryzbyj.telsasoft (charmander.telsasoft.com. [50.244.222.1]) by smtp.gmail.com with ESMTPSA id r13sm6872379iov.11.2022.01.11.18.20.27 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Tue, 11 Jan 2022 18:20:28 -0800 (PST) Received: by pryzbyj.telsasoft (Postfix, from userid 1000) id 30F18800C62; Tue, 11 Jan 2022 20:20:27 -0600 (CST) Date: Tue, 11 Jan 2022 20:20:27 -0600 From: Justin Pryzby To: John Naylor Cc: Peter Geoghegan , Masahiko Sawada , Andres Freund , "Bossart, Nathan" , pgsql-hackers@lists.postgresql.org Subject: Re: do only critical work during single-user vacuum? Message-ID: <20220112022026.GC14051@telsasoft.com> References: <20211221034630.maoteglpjqpgh62g@alap3.anarazel.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.9.4 (2018-02-28) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Tue, Jan 11, 2022 at 07:58:56PM -0500, John Naylor wrote: > + // FIXME: also check reloption > + // WIP: 95% is a starting point for discussion > + if ((table_xid_age < autovacuum_freeze_max_age * 0.95) || > + (table_mxid_age < autovacuum_multixact_freeze_max_age * 0.95)) > + continue; Should be && Should this emergency vacuum "order by age() DESC" ? -- Justin