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 1pkAEB-0005id-0e for pgsql-hackers@arkaria.postgresql.org; Wed, 05 Apr 2023 20:59:35 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1pkAE9-00022f-Rf for pgsql-hackers@arkaria.postgresql.org; Wed, 05 Apr 2023 20:59:33 +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 1pkAE9-000221-F7 for pgsql-hackers@lists.postgresql.org; Wed, 05 Apr 2023 20:59:33 +0000 Received: from mail-vs1-xe33.google.com ([2607:f8b0:4864:20::e33]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1pkAE6-0000TM-OF for pgsql-hackers@postgresql.org; Wed, 05 Apr 2023 20:59:32 +0000 Received: by mail-vs1-xe33.google.com with SMTP id z17so26035733vsf.4 for ; Wed, 05 Apr 2023 13:59:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bowt-ie.20210112.gappssmtp.com; s=20210112; t=1680728369; 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=8A/NZN3rSddhVAX/WY8izbsEt0bmnRnhvS9XORfxOYI=; b=fTx+IBbjegWUBv21uBtOcpMm/+0su8irbxCo15uaZxQSqzE7nSIi4+FDlF4vjt/sRn c1ynFcsRZ+TPUtdQMjKG5AozSZMDGhkzQ7l397TJrb3CQmA5V6Re3RsZKd+8W+q4mn4i thWVQZW2ajKChDpvSQeMn9k10O6kmAlAGhrTZo5KOobTyw9capzcPq18ypg5QBeSHPQP YanUOQXLg8tRMF+dnnXCKyJLBdi4U3sICb+ttxgJwzyb0NEjH6DT/h+TBsrhUusXYFL9 mKsrsEnokSvwUwulXQQSNwzWKzWDLVUWVcCvA1Xi/i9IG87SEjyTFHp/JU7e5JGhEkOW iQkA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1680728369; 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=8A/NZN3rSddhVAX/WY8izbsEt0bmnRnhvS9XORfxOYI=; b=vRyJbF6plMv55LCek8hZUMEwUF7t0MVGtfecNzcaKm/EtM8ri3Urjg/W1TU1yajYUD n33ivikW/cT9epwBZq9LZ1dfAKbJNeiHPYq+a1c0V7XkiSv+4VuEQSdWHl7y5F8FWqbb If6QwRPdb5YHBj8sTw53R4frs6KZW9MDafsFOPSzYfxTqbRyPHz2aUinjWJgpoV9vfCu W6H8J4KV4EjWFt43ZFkdVVCmwpYhsIAYGYnTB53dKGIVMz+U3OwXOQ80wDHhyQ8UEn5Z WeUx9DIOQpZkA5BpE8N6YIM7rpFFAJxAxPhoXrkaX4EFCBTJzejjDcLH7kqbTf7ZAaF9 LzeA== X-Gm-Message-State: AAQBX9eqCuygDRkLVvcSHaKACHadfl1+4+N60LQsvuDOhTpvLhvKa9YP NoruTFUo3EftBnGxS3XiMqeiCH3tZomMXKcVnNbMCg== X-Google-Smtp-Source: AKy350ZEh2A16klu+F3Zp8KSAWcRv0pt0NUuMSuGfNnU17/YfoQZym57yJysB85mV6Ba5bgNafgY12pXu2cYWO8k3FA= X-Received: by 2002:a67:d390:0:b0:412:5424:e58e with SMTP id b16-20020a67d390000000b004125424e58emr3182185vsj.0.1680728369662; Wed, 05 Apr 2023 13:59:29 -0700 (PDT) MIME-Version: 1.0 References: <20230329.132155.629765142788133576.horikyota.ntt@gmail.com> <20230329.173456.1185961934810139447.horikyota.ntt@gmail.com> <935191FB-083B-4060-89FC-466F61FAA391@yesql.se> <1252075.1680547394@sss.pgh.pa.us> <20230403190837.qubpnwugfe2k2g46@awork3.anarazel.de> <7E06F879-7E20-4A6A-862F-CA72CDC9A323@yesql.se> <800860D2-AEE7-4D23-A5C0-9182EC252554@yesql.se> In-Reply-To: <800860D2-AEE7-4D23-A5C0-9182EC252554@yesql.se> From: Peter Geoghegan Date: Wed, 5 Apr 2023 13:59:03 -0700 Message-ID: Subject: Re: Should vacuum process config file reload more often To: Daniel Gustafsson Cc: Robert Haas , Melanie Plageman , Andres Freund , Tom Lane , Masahiko Sawada , Kyotaro Horiguchi , PostgreSQL Hackers , Amit Kapila 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 Wed, Apr 5, 2023 at 1:38=E2=80=AFPM Daniel Gustafsson = wrote: > Not to derail this thread, and pre-empt a thread where this can be discus= sed in > its own context, but isn't that kind of the main problem? Tuning autovac= uum is > really complicated and one of the parameters that I think universally see= m to > make sense to users is just autovacuum_max_workers. I agree that it does= n't do > what most think it should, but a quick skim of the name and docs can prob= ably > lead to a lot of folks trying to use it as hammer. I think that I agree. I think that the difficulty of tuning autovacuum is the actual real problem. (Or maybe it's just very closely related to the real problem -- the precise definition doesn't seem important.) There seems to be a kind of physics envy to some of these things. False precision. The way that the mechanisms actually work (the autovacuum scheduling, freeze_min_age, and quite a few other things) *are* simple. But so are the rules of Conway's game of life, yet people seem to have a great deal of difficulty predicting how it will behave in any given situation. Any design that focuses on the immediate consequences of any particular policy while ignoring second order effects isn't going to work particularly well. Users ought to be able to constrain the behavior of autovacuum using settings that express what they want in high level terms. And VACUUM ought to have much more freedom around finding the best way to meet those high level goals over time (e.g., very loose rules about how much we need to advance relfrozenxid by during any individual VACUUM). --=20 Peter Geoghegan