Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1vEQ1M-00BSg6-Ag for pgsql-hackers@arkaria.postgresql.org; Thu, 30 Oct 2025 10:36:43 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1vEQ1L-007Y77-8J for pgsql-hackers@arkaria.postgresql.org; Thu, 30 Oct 2025 10:36:42 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1vEQ1K-007Y6q-VS for pgsql-hackers@lists.postgresql.org; Thu, 30 Oct 2025 10:36:42 +0000 Received: from mail-lf1-x134.google.com ([2a00:1450:4864:20::134]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.96) (envelope-from ) id 1vEQ1I-004XzE-19 for pgsql-hackers@postgresql.org; Thu, 30 Oct 2025 10:36:41 +0000 Received: by mail-lf1-x134.google.com with SMTP id 2adb3069b0e04-591eb980286so905802e87.2 for ; Thu, 30 Oct 2025 03:36:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1761820599; x=1762425399; darn=postgresql.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=HL02I4Gvc0sPyhbQ10FTEExD39pqkulpgoBXgofpReI=; b=XdocBifG6tHWxu4TOKpf35XgMMymjUKhftLXtSnPEbWsJuv++ud2/hOPKQLlpz2RXL 59ehpgRHqoYqzo0URdhtmmqgrfkaNgHF3jN4sV2pGiCtf+eIBdIP7BwIqI3gbOO6Gol9 SabyGPmvXjov0jT8MM1VPsFPWLB6wgYVP0+0u/WQtNmF/FoVLpcfp7lpWLww3JGD3U67 MuQ7JHN98NfLAhs+Vbzog4y6CqXLaVDnX1Y6FI5lLChn8haSGYjHX382oEZiZDdjwZwZ Sfz3uhknT8/5Tz7yS1qSxAr718tpqE+YUVaDSibskjS3AjMzx5EJA3oHDlQfVmPF2X6I WTdg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1761820599; x=1762425399; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=HL02I4Gvc0sPyhbQ10FTEExD39pqkulpgoBXgofpReI=; b=tsQvcRyQDnYXVvnAhBCEdZr8wUI2gNk3rQlm4i1T3uUSbvvxkQsKSacbZ8+8u1MkG/ ppqN4L1+X4Gq70bPJyJ/pIZMwBAKS72q8U0AOleKqNvB/abtGcHFtvDbkx36mWd3SKuh MwF6PPMcHF2nGPBeJZjfhsvY6jsIXU1SgqW6j28XzshOhdygz7RGnL0Fm81QBUfTWgzf genzlCTJ8QWQ7fiUxAcBqYHwmUqUQcd431BRyU8fDs+3JdImMLRZlf6KpM12kDzvIJlf J78EUlKjEf4pz+H0p6uNPmZ82lruu8o9Lmc5m0kc0zYYd6J/1BAFdTOjb+XZsEtqMY/I wZow== X-Forwarded-Encrypted: i=1; AJvYcCVNkARlI/vGP5ijwYhxI0QDte+bL5TpoB+1a/EL/olsujdor9xgS81Vo2Ul2lR++Gkld+o4NbGWRMwszHXm@postgresql.org X-Gm-Message-State: AOJu0YySRpx0f33KMqA+Q2H4TLyQc5xSHquzjeby+iIUoEBkYhoXmpFL l/YUM86Nap/hPFFEmMy3eIKpXdHPIHb06Lzp4QAmBe2FELn6oAwbLtrN7vIyyTdiiFZV8P/DGOl 55nv0uuom3GhPO3kODNfxlrN7NHZ1LgQ= X-Gm-Gg: ASbGncv7sQiRFX0p47oAFT/2s9RGdlD/N7YZt1mSCSmCF6Skcu5Q77w92IZxKmX6Jqk ohFVHhnjmIOv94ZbaDOsvwxHOmoMGyMRWSDrQlJd+FUaHZvtv/LF8swd2pW8JABDG1HytFJkwPA VdWlLZFgbPQsThQuOUCngUh5jIdHIQTrxLgZoHsdDr4wj/SevSg4n3Bw4/usX/3Mra3hnUnh5QC tYPuyXrwLtBglC+c8n3PK9hvW2Xhqg/rtsJzi/SXmeXdQCxde6sICA0F8zNqKFHUog00cfpI4/7 L7Z5oE6PUiqdcoLdVKrCJQZfqjKS5wZt8iOvke3SI8nGVkS2/2s= X-Google-Smtp-Source: AGHT+IGiPO+yXSJI1DHMrj+gNQUoXsKqKoJbD2RWoVcpBCkFyaATkkmeXnGCaMl/VSnh8E8pyAOWkbyntT3biXjvU1Q= X-Received: by 2002:a05:6512:1247:b0:591:c8de:467b with SMTP id 2adb3069b0e04-59416ee13cbmr910348e87.40.1761820598489; Thu, 30 Oct 2025 03:36:38 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: David Rowley Date: Thu, 30 Oct 2025 23:36:25 +1300 X-Gm-Features: AWmQ_bn_VZNPtPRUlgix6sG5dxfvux4rXyW8zp3T7kyYG0KGBRpPyRGk5RggJi8 Message-ID: Subject: Re: another autovacuum scheduling thread To: wenhui qiu Cc: Nathan Bossart , Sami Imseih , Robert Haas , Jeremy Schneider , pgsql-hackers@postgresql.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Thu, 30 Oct 2025 at 19:48, wenhui qiu wrote: > I think there might be some misunderstanding =E2=80=94 I=E2=80=99m o= nly suggesting changing > effective_xid_failsafe_age =3D Max(vacuum_failsafe_age, > autovacuum_freeze_max_age * 1.05); > to > effective_xid_failsafe_age =3D (vacuum_failsafe_age + autovacuum_freeze_m= ax_age) / 2.0; > In the current logic, effective_xid_failsafe_age is almost always equal t= o vacuum_failsafe_age. > As a result, increasing the vacuum priority only when a table=E2=80=99s a= ge reaches vacuum_failsafe_age is too late. I understand your proposal. The autovacuum will trigger for the wraparound at autovacuum_freeze_max_age, so for autovacuum still not to have gotten to the table by the time the table is aged at vacuum_failsafe_age, it means autovacuum isn't working quickly enough to get through the workload, therefore the problem is with the speed of autovacuum not the priority of autovacuum. David