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 1sJg4q-006B1i-31 for pgsql-hackers@arkaria.postgresql.org; Tue, 18 Jun 2024 21:09:16 +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 1sJg4n-003bNJ-Tg for pgsql-hackers@arkaria.postgresql.org; Tue, 18 Jun 2024 21:09:14 +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 1sJg4n-003bMV-K1 for pgsql-hackers@lists.postgresql.org; Tue, 18 Jun 2024 21:09:14 +0000 Received: from mail-io1-xd36.google.com ([2607:f8b0:4864:20::d36]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.94.2) (envelope-from ) id 1sJg4m-001yRH-2G for pgsql-hackers@postgresql.org; Tue, 18 Jun 2024 21:09:13 +0000 Received: by mail-io1-xd36.google.com with SMTP id ca18e2360f4ac-7eb7c0f9784so247247539f.2 for ; Tue, 18 Jun 2024 14:09:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1718744951; x=1719349751; darn=postgresql.org; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=99/sQjmEyDJfEHPgv4GBv3OKZYcFsrEQg1ycFI5CODQ=; b=TsKpri4u0IdZYzDt6+om+OrJgb5MX/OhNTXR7tYLlNGbEHMkM4zeNsNudF8ed4T7Y6 jmYToEoRhuCJSD8vDZZO9NmUvxBL5LmAPbhBmObbP0VIdBKTervQukyYp3kN6CUXBQLG UICpWuGFSHTIk/SXrqLeq+PhNwic4O316/aWRIFvoa7qVtQe+Y2LzYAhETq3bk8jcLQ4 bQrLPTdlKHR6jaHJl1jnhifh2m7N4ezsKrefFr5j7o9tVFdL5e17GEeAifMIhmFRbcPq RmXp9F9bkkt9LvhclgAsRtM+MrwMeDqedqHCTvQ+39LiVkxwXARHq2GgRe1SulNsAeIH Gsmg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1718744951; x=1719349751; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=99/sQjmEyDJfEHPgv4GBv3OKZYcFsrEQg1ycFI5CODQ=; b=h0/hCQHdDLAj9uCvf3wG2A0A+x7dxSJoOWn4nAz5au5XLw203YLzzjAGT2IcA73WIZ wZ1jIHGTTsBYNHz87P8kguz/POk2jpTLpt6VOJODiJ+BIlFIIegQLf3lh6LqqnhcQyK+ mEsUHZCf/2MTP7/6XBKSf5/lN2VS0iuGGqvMV/qQ80PbpJTU98msoowTlfP8f1/+eVop U74tQ/5DSYR7m6pX+7wC9X32Q5JVS18IxeI5GjD7kuhzhBefEqAihfag2ePZFB++QEGq bUc3u3lQ/IIjb3aw/qlp2caTBm1X8jDifZbiAryI8/C7ahr5qokdaDI78ekTn4OMbDsZ Giow== X-Forwarded-Encrypted: i=1; AJvYcCUYJ3MmHsVfk7AX7OuXefMzHtza6gloGIdgtbZ5TKtRVJTBP4ZYECHdD5dMUMOfQxt47Dlp1Jd47/cMDOTOiHP+QZcynszV08vnc/o6 X-Gm-Message-State: AOJu0YzvPhKyUH9WNASXEOEULUImanR0Md+vUQ8oRoAGtLBiOegGK678 T/hdIOvkq4zUl+o1RYmjUbPRNkUbH3t4OLJ1bgl2faQo6k+kqVJ2 X-Google-Smtp-Source: AGHT+IFPSvR6aYZhAKlaPgzEdk0gcTRYAdO5OfWAYRJPaoB32j91b68dpSI7LLdakzrTaOGQ2GzhyQ== X-Received: by 2002:a05:6602:2dc1:b0:7eb:f3c8:c59f with SMTP id ca18e2360f4ac-7f13ee26cc6mr111455339f.11.1718744951119; Tue, 18 Jun 2024 14:09:11 -0700 (PDT) Received: from nathan (162-195-168-172.lightspeed.stlsmo.sbcglobal.net. [162.195.168.172]) by smtp.gmail.com with ESMTPSA id ca18e2360f4ac-7f13b7b4143sm24224339f.49.2024.06.18.14.09.10 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 18 Jun 2024 14:09:10 -0700 (PDT) Date: Tue, 18 Jun 2024 16:09:09 -0500 From: Nathan Bossart To: Andres Freund Cc: "Imseih (AWS), Sami" , Justin Pryzby , "pgsql-hackers@postgresql.org" Subject: Re: allow changing autovacuum_max_workers without restarting Message-ID: References: <2780DB08-DCA6-4E57-B823-303A0E7E17D7@amazon.com> <20240507160605.GA2523153@nathanxps13> <011CA929-4933-40EA-B1D3-29131FEFBCF0@amazon.com> <20240517021646.GA1745636@nathanxps13> <20240603190852.jcibstxflb33hjvu@awork3.anarazel.de> <20240603232427.pjiyqggsr7duccr5@awork3.anarazel.de> <20240618204334.i5ar2fie4vbb3fhm@awork3.anarazel.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20240618204334.i5ar2fie4vbb3fhm@awork3.anarazel.de> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Tue, Jun 18, 2024 at 01:43:34PM -0700, Andres Freund wrote: > I just don't see much point in reserving 256 worker "possibilities", tbh. I > can't think of any practical system where it makes sense to use this much (nor > do I think it's going to be reasonable in the next 10 years) and it's just > going to waste memory and startup time for everyone. Given this, here are some options I see for moving this forward: * lower the cap to, say, 64 or 32 * exclude autovacuum worker slots from computing number of locks, etc. * make the cap configurable and default it to something low (e.g., 8) My intent with a reserved set of 256 slots was to prevent users from needing to deal with two GUCs. For all practical purposes, it would be possible to change autovacuum_max_workers whenever you want. But if the extra resource requirements are too much of a tax, I'm content to change course. -- nathan