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 1scSGC-007QKJ-Sy for pgsql-general@arkaria.postgresql.org; Fri, 09 Aug 2024 16:14:37 +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 1scSGB-004XFD-HP for pgsql-general@arkaria.postgresql.org; Fri, 09 Aug 2024 16:14:35 +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 1scMDk-002W9s-Fi for pgsql-general@lists.postgresql.org; Fri, 09 Aug 2024 09:47:40 +0000 Received: from mail-vs1-xe2d.google.com ([2607:f8b0:4864:20::e2d]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.94.2) (envelope-from ) id 1scMDi-003rmW-05 for pgsql-general@lists.postgresql.org; Fri, 09 Aug 2024 09:47:39 +0000 Received: by mail-vs1-xe2d.google.com with SMTP id ada2fe7eead31-493d7455231so580738137.0 for ; Fri, 09 Aug 2024 02:47:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=dbtune.com; s=google; t=1723196857; x=1723801657; darn=lists.postgresql.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=cWbr3bUoaQ/KVespis4BFcuh0x09rphJcEIaa6Kqyn4=; b=hNn/r7c5fiJgVh1WkMu5GbyVum/5fYNXtuI5oN32BrepcB3sSWrn4j8xu6PMxHjZ7B wQirzcSRNkV1tm2hun+R1Z02Ts+XgjArY+Nns9rJl3yV6V/fZK3OXEDzS0Pw2P1CQ8df cO6BwD76MyXI64/E/HDCumoNfhCN7+Qit0N+1pxq3Gv67nZvWlS9V2VxoAzJwW82UDej QekbpPI54GR25EJNIfG2/zWykBGxy3HGZj3Hw8aI34YxWfe6b4Ef5zMRlSmQThrHEGfi BWJpcqRPP5TObIsbhRNHjd6q8b1P0FnGN22fLsFj1NVJIIw35czzzUU5eiqcCvKcIeL0 h5IA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1723196857; x=1723801657; h=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=cWbr3bUoaQ/KVespis4BFcuh0x09rphJcEIaa6Kqyn4=; b=Ch0bqrLX9NA8BlPYj5n4bprgJLrChn7gaeEUXxTgM8bgUSyXQbut/L3mWdTOIrJDyJ 6AgB/T+vpGNv2i654Hicxkq1ZT7m1Q2exd67xgzOoveRWZVePnNgunO/wZLX5lOQnwIi 2tDN0BHf21sBMrZc5v26SQuU10IV1gpcxyQrm7LRCeuWBtfpAXTNOeSJJi1BzarVqACW qa+0xdwG9Ee3dsiQqbruuzqgOphB/QyxVb1jAEhlhKDxrny8FtYh1WUORwKuHP9+xGX4 j/7QVwS18UvnaYlRZius+0wZB9zzkjvIP4I1AHMDNu/aBngnx8GUYQnUxob+99IsPvzr MSHQ== X-Forwarded-Encrypted: i=1; AJvYcCX1t+ytyWuDvP/0zEQJn0cZj6ba4Az+gA2JGXxM/IcKQQLAXd43mS+xI/lRmIruHnJp9k8d/Sd1DP4bkuuqeCX8R41gOVH+j9kRHUS4z5K/jaD2 X-Gm-Message-State: AOJu0YyKdya42i+aMtw4Qr/w4HVGxU71v8y3q1/cLmTMw+ZZknJp2UV2 VwdcvfPZABmXjk3QDJpZOvxJL171hm/Y3cIRA0MUr7X9moBsku9qDh7e9XWbEhMYGv8kAc5mLTX 4GoMtnhiOLcr1edqfQHIeo/mqAC1ldxPAeGrc3A== X-Google-Smtp-Source: AGHT+IGmiBTCTsXTcMyEjZfP3kanBpnEV10d/O6LtgcvOfm83GaIU1+wg6uehfVDHA1jCnMdulqO4v7XwB50f0w3lYA= X-Received: by 2002:a05:6102:c02:b0:492:9927:a5c6 with SMTP id ada2fe7eead31-495d841d6a8mr1063607137.12.1723196857168; Fri, 09 Aug 2024 02:47:37 -0700 (PDT) MIME-Version: 1.0 References: <66D17234-043D-457E-8607-5126B4FBC3DD@thebuild.com> In-Reply-To: From: Costa Alexoglou Date: Fri, 9 Aug 2024 11:47:26 +0200 Message-ID: Subject: Re: Vacuum full connection exhaustion To: David Rowley Cc: Christophe Pettus , pgsql-general@lists.postgresql.org Content-Type: multipart/alternative; boundary="0000000000008cd40d061f3d0863" List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --0000000000008cd40d061f3d0863 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Fri, Aug 9, 2024 at 1:02=E2=80=AFAM David Rowley = wrote: > On Fri, 9 Aug 2024 at 02:12, Christophe Pettus wrote: > > VACUUM FULL takes an exclusive lock on the table that it is operating > on. It's possible that a connection becomes blocked on that exclusive lo= ck > waiting for the VACUUM FULL to finish, the application sees the connectio= n > stopped and fires up another one (this is common in container-based > applications), that one blocks... until all of the connections are full o= f > queries waiting on that VACUUM FULL. > > I also imagine this is the cause. One way to test would be to do: > BEGIN; LOCK TABLE ; and see if the connections pile up > in a similar way to when the VACUUM FULL command is used. > > David > Thanks folks. David really straight-forward way to test. I validated this, when I lock the two tables involved in the benchmark the connections are constantly growing until they reach the `max_connections` --0000000000008cd40d061f3d0863 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
On Fri, Aug 9, 2024 at 1:02=E2=80=AFAM Da= vid Rowley <dgrowleyml@gmail.com= > wrote:
--0000000000008cd40d061f3d0863--