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 1nJyd1-0005mg-RW for pgsql-hackers@arkaria.postgresql.org; Tue, 15 Feb 2022 14:16:27 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1nJyd0-0003mj-Pe for pgsql-hackers@arkaria.postgresql.org; Tue, 15 Feb 2022 14:16:26 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nJyd0-0003ma-GJ for pgsql-hackers@lists.postgresql.org; Tue, 15 Feb 2022 14:16:26 +0000 Received: from mail-lf1-x136.google.com ([2a00:1450:4864:20::136]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1nJyct-0005Q5-Ay for pgsql-hackers@lists.postgresql.org; Tue, 15 Feb 2022 14:16:25 +0000 Received: by mail-lf1-x136.google.com with SMTP id b9so12969730lfv.7 for ; Tue, 15 Feb 2022 06:16:19 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=EJXb1OiPsM9tpRvaWwmpilpO6GvtgqbIMpK2mjAloHg=; b=Z5ndX9gjCuf4jd0PGcnX3AxqwGiLwFzKMuQKNtZ5E17JTK1/lvcy7lZCUHzelxU1Zg WjjyPtLBUINrJLeLm9WeewzjwzGJFl0VGZqpchAOnaGFVKxSz0ispknQHAvmMFVtLcwh Jsbml9FXK8ux8+18NXpXpUOUhJXEMKqfcsJjxxJmvbYtZlr3xALYSvLKkdVtxj+oLWac H8nilkmObYsa/RjqGW6CQ5MSJTF3FiecQBxeNzDos9aPemvedSaQoFGJenRcraEAslDM lcIsDDgsPKn56/qQVwp5mdiP798z6WASoVNeJX4Mw6E1EDSDZ++13Xp+QlEmzoUCgz4u xcYw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=EJXb1OiPsM9tpRvaWwmpilpO6GvtgqbIMpK2mjAloHg=; b=1YwoIq9PWQ3xX8oi3phL5LwWmK6hafYfoPQeHImb68pmPtF9VQUEF+Tk1TsutgJcx/ mvwMAdPWdqcTBSUxRI3mw9eVWWWrxtjN4R7qWe+yhTzxT7WcVsF+1I26KHLdwNli5rBt mgIg+d1xc2ubXeg5ulMZtJDcssZmFkUPckCsWrwK9NW+mhuXEhHMbhcGVvRjSTpccqk2 KEfrCycfpiIgOiSz7i0eC1Tz9dxjtkXkFKgy/miYkFkpDKS2hWdMpCJ48ReCZzOqFp+o QDcNnSJJU0Hg+l1wLVI/K8ApJ5qaOgykq8RC/RcWpQDC6FmebmKGGdtU/1cF3aUx7kNs tfEg== X-Gm-Message-State: AOAM533p+bHMtU8C4PmWYo/F2U8d/Gm4QZtS4HzWd/ev0+3YwZ+UCCwr SiLczm7PQzksqiiVu4N/TDk0nll7vdQ9vrqxPY8= X-Google-Smtp-Source: ABdhPJzI1qFsc2HAiVzp07ze3vtEfxY88iSCmARk7+3Iu54afquDwTFRtpCpTWQUrodswd4gS9M/cpjue1tqjWvq63A= X-Received: by 2002:a05:6512:4023:: with SMTP id br35mr3313315lfb.368.1644934578093; Tue, 15 Feb 2022 06:16:18 -0800 (PST) MIME-Version: 1.0 References: <20211210015616.o242b4xchhpglfcy@alap3.anarazel.de> <20220203215048.rmwjzixdzaetedxq@alap3.anarazel.de> In-Reply-To: From: Robert Haas Date: Tue, 15 Feb 2022 09:16:06 -0500 Message-ID: Subject: Re: do only critical work during single-user vacuum? To: John Naylor Cc: Peter Geoghegan , Andres Freund , PostgreSQL Hackers Content-Type: text/plain; charset="UTF-8" List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Tue, Feb 15, 2022 at 1:04 AM John Naylor wrote: > Well, the point of inventing this new vacuum mode was because I > thought that upon reaching xidStopLimit, we couldn't issue commands, > period, under the postmaster. If it was easier to get a test instance > to xidStopLimit, I certainly would have discovered this sooner. When > Andres wondered about getting away from single user mode, I assumed > that would involve getting into areas too deep to tackle for v15. As > Robert pointed out, lazy_truncate_heap is the only thing that can't > happen for vacuum at this point, and fully explains why in versions < > 14 our client's attempts to vacuum resulted in error. Since the > failsafe mode turns off truncation, vacuum should now *just work* near > wraparound. If there is any doubt, we can tighten the check for > entering failsafe. +1 to all of that. -- Robert Haas EDB: http://www.enterprisedb.com