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.96) (envelope-from ) id 1vaFZ1-005piq-0c for pgsql-general@arkaria.postgresql.org; Mon, 29 Dec 2025 15:53:43 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1vaFZ0-00HDRu-0Z for pgsql-general@arkaria.postgresql.org; Mon, 29 Dec 2025 15:53:42 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1vaFYz-00HDRk-2j for pgsql-general@lists.postgresql.org; Mon, 29 Dec 2025 15:53:42 +0000 Received: from mail-ot1-x330.google.com ([2607:f8b0:4864:20::330]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.96) (envelope-from ) id 1vaFYy-003Q9i-0M for pgsql-general@postgresql.org; Mon, 29 Dec 2025 15:53:42 +0000 Received: by mail-ot1-x330.google.com with SMTP id 46e09a7af769-7c6d13986f8so7605027a34.0 for ; Mon, 29 Dec 2025 07:53:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1767023618; x=1767628418; darn=postgresql.org; h=to:subject:message-id:date:from:mime-version:from:to:cc:subject :date:message-id:reply-to; bh=ij47GhFiFhx31n/DQ/h6RBMx0k3g2ZpvYpSXjim+Fuc=; b=ComXrLlmJ/dO+wFZq/47LY/osudpKNOuTvnUoL7QWT7v5UX36EhhJdiA0dl5YSE2s2 AS5mmZ/QTsdX+oKSH1IOiuZ3r9afWrRy+9ig24uzNZYwiyg94OpGho51GwBxubsRlCSw Q3rbfdnNWCAL6+5AeNyxqF5AsUawHGrCJ6zzs9h061m8ASp9tKptoXNuG22qxFqdr5xv fMLXmE83q27pRcxuiQXNder+gLjszGAieIiqGwwyCIRs5Ea0tZZ5LD4CSb4ehi1F6uzK YPuqzFILTlGh1jmt029y8PneVIHDtIoii3WjikxKxaBV5kKFkh8+EXGZtmgQIJbo9Io/ sssQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1767023618; x=1767628418; h=to:subject:message-id:date:from:mime-version:x-gm-gg :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=ij47GhFiFhx31n/DQ/h6RBMx0k3g2ZpvYpSXjim+Fuc=; b=feET1W2XNsXVvchwGgEyrPjpk+jmO9yiaFFSLL5Np1W/Rd7UKGUoA/ORuNJjwWsnw1 rX5s/ACxbz+ekwE5wzw4gMthl3aPPLsY7L1diZQFHeJzC7yMSYKkKhT/2paGMnUk633/ Fx+gNw1GDv4XxhsfjboQCbL+PhdDfRW09I8Z6VtDNSgEiY3/R7qatSLtllE1lj1WOnsO 72ZH+XR0rUq+3xeo+SSg6Wn2TL06sT88XcvLp8a4xXgjp3oRT/hB+ez7GoNEMBbWPtCA mCi6FBOcsbTu0jCoJ6nXro2EsX3LhobP3TwEcntsRbIPXyk/Hf/4ITjQmU4qi7/lqNvx il4w== X-Gm-Message-State: AOJu0YzVPlsAF2+nrBgUNV+EZTs/NHo5LCnMpqGERLgjD2rHPiJkRMBE tNRZmaLzCK+P1qel5FKXBPtnFPzI/Tgqvel91dkyi9gZeM7erp3SX6QltY+J2G2g7D7Wy+qRtk9 /aWpOO+1r3mKARaByQ205pl3e//pePvhi8Shn X-Gm-Gg: AY/fxX7mtrAqcr8apeIvIccOUcIuYCN7t4agc0PspmE8UR0lvleroVGnJt8xDmOOLXg t+6+ctfFLMiCDODzWkspBobNBLA5A3JeysI+45w9y2MpTLeHPfvWR0FfkWBVTuKjobc5NL+LUVe y1RoFcDZFn6YS3qpgHV3brEytgD3yfvIm9fl0rKVXwgfj6Puysft5QQFCdT4hyBgBzPQ4wz7yZX VmrskcPg6B1jyeC26HRv99Ozy3bNvzvHu1eKbabEa/o+pJy3d+e4dpzZR/yOqv4Cre3q5Y5yg== X-Google-Smtp-Source: AGHT+IG74ASpKrEQLUMk7WtA7i3yIupt8Od9hjKh6xE3ShxtoFBhWJrzVlLm1C5BwZ65aF+aBTst5OFqv+cUw/FXs7A= X-Received: by 2002:a05:6830:1553:b0:7cd:f5dc:56ea with SMTP id 46e09a7af769-7cdf5dc5750mr1988445a34.4.1767023618213; Mon, 29 Dec 2025 07:53:38 -0800 (PST) MIME-Version: 1.0 From: pramod gupta Date: Mon, 29 Dec 2025 21:23:26 +0530 X-Gm-Features: AQt7F2o24dkk34YpHdieZdzqaWByyixEcT1QC4Mf2Ca9Sdk5fQaLk3aXVQl8Ido Message-ID: Subject: How did VACUUM ANALYZE reclaim large TOAST bloat at disk level in PostgreSQL 16? To: pgsql-general@postgresql.org Content-Type: multipart/alternative; boundary="00000000000012cbd20647193f81" List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --00000000000012cbd20647193f81 Content-Type: text/plain; charset="UTF-8" Hello Everyone, We have a table with a total size of ~628 GB, out of which ~601 GB was TOAST data. After running VACUUM ANALYZE on a weekly basis, the table size reduced significantly to ~109 GB, indicating a large amount of bloat removal. I would like to understand: How was VACUUM ANALYZE able to reclaim such a large amount of space, especially for TOAST data? Under what conditions does PostgreSQL reclaim disk space without requiring VACUUM FULL or CLUSTER? Is this behavior expected in PostgreSQL 16, particularly for heavily updated or deleted TOASTed columns? Any insights or documentation references would be greatly appreciated. PostgreSQL version: 16 Thanks in advance. Pramod Gupta --00000000000012cbd20647193f81 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hello Everyone,

We have a table with a total size o= f ~628 GB, out of which ~601 GB was TOAST data.
After running VACUUM ANA= LYZE on a weekly basis, the table size reduced significantly to ~109 GB, in= dicating a large amount of bloat removal.

I would like to understand= :

How was VACUUM ANALYZE able to reclaim such a large amount of spac= e, especially for TOAST data?

Under what conditions does PostgreSQL = reclaim disk space without requiring VACUUM FULL or CLUSTER?

Is this= behavior expected in PostgreSQL 16, particularly for heavily updated or de= leted TOASTed columns?

Any insights or documentation references woul= d be greatly appreciated.

PostgreSQL version: 16

Thanks in ad= vance.
Pramod Gupta
--00000000000012cbd20647193f81--