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 1wYIAc-000Aj4-0F for pgsql-admin@arkaria.postgresql.org; Sat, 13 Jun 2026 06:48:42 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1wYIAZ-002r0l-26 for pgsql-admin@arkaria.postgresql.org; Sat, 13 Jun 2026 06:48:39 +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.96) (envelope-from ) id 1wYIAZ-002r0b-0y for pgsql-admin@lists.postgresql.org; Sat, 13 Jun 2026 06:48:39 +0000 Received: from mail-lj1-x230.google.com ([2a00:1450:4864:20::230]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.98.2) (envelope-from ) id 1wYIAX-000000007hp-20cr for pgsql-admin@lists.postgresql.org; Sat, 13 Jun 2026 06:48:38 +0000 Received: by mail-lj1-x230.google.com with SMTP id 38308e7fff4ca-39677c434efso15404541fa.3 for ; Fri, 12 Jun 2026 23:48:36 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1781333314; cv=none; d=google.com; s=arc-20240605; b=Z4CdQH0e4Y+yoakZzhiEaS3aUS+iasyXbV4AlbNY3ofcS2C5oNPMJ6tppCYjfpAYNN bjGxz52EIwtitgaKMdYTlIUJhtzNiY+TBbxnY7h6Ul1bg2+PfM+KgoGd5fbt4DLOYKn3 fYCVV+Z4il428U32g9onHIszPk5qd5vfMK6pqP/QPsXsQDl9THIYmVB0LGClTVEadkGl RYlQ4tKcKgDJlN6LcZGMD8msQnajWkoBI9mnlAtw0yAOszTvntQhf23bjprkK33vrkWi /cKVjUZvWNOjP+OBZBli5DLITFB/KPjj44+8UGQskxZbnfw1+82QF2nt6XUL9qoCq1rt lBHw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=to:subject:message-id:date:from:mime-version:dkim-signature; bh=q3ygVecu9sCszvX3xhaj/XNu9UN8EmkTc8ogWx/RtrY=; fh=druxZHa2fk4e6MLibibygn9AWWgeaAPo4m8Gpo2MBXU=; b=B5KbjIdg3VHNoByy6Bpf2QtddyKz7eZ5HXSuATxJFbis8BiBOEXcdxt7uc8rCwjN9j pgDZ9TrxK39qqZ28ZI4ru51dcId5DH9QIS3oX0EqFny/svHytLY4gEI9L0Mnvh1AcWEg GS1RbfQ3JBNBVyYYdM27a0nQTr6591LNnf+rM8wD3kq/izReZDBw88OyjDHg/Ewi9uJ3 mj8QH6QcmD01G+RhhJGssRoVOhbn2UZ3+6+/+shbyJuy2nhNQs/QnkTCd7OSdaH5iHJz 68SjB7TzM6BKnIdoWlCNQly3sFxwICnuMdiX5rOmJyC+tob54U8krTHOKUx8T9EAKUjg 9+cQ==; darn=lists.postgresql.org ARC-Authentication-Results: i=1; mx.google.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1781333314; x=1781938114; darn=lists.postgresql.org; h=to:subject:message-id:date:from:mime-version:from:to:cc:subject :date:message-id:reply-to; bh=q3ygVecu9sCszvX3xhaj/XNu9UN8EmkTc8ogWx/RtrY=; b=oJE3HdCiqqdF13uaDrgbmqVa9hMwoBMJF3wtjoK9WrfaLX3Om4K4VdOd0bcWwQbsQ+ wB/jhkAPBBgIVd1jP8INSOT+9XsnuxA0htad9lZc7pLDI9RFzhBz9vAbTMTu6OnQUQYW ZFTTcQ4KlmbDcwXLA5s502Yvbzz92IFhs1D3xudsHsCOCvDv8BtquxEwoOVRqP73Oe0z FpqCCN5ovqL+jPHlKX9h5nZUiSZI/wJUOVmyYPqw9kkehIf2sADFTm9Lds0pcDQdUukS FGFiY6odjlfYcPeGCY8ZTlEKYxNw9b92PgPOvcWuqDji3Ovz5US0cCy0nJ0xLY6cgH+P IDWg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1781333314; x=1781938114; 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=q3ygVecu9sCszvX3xhaj/XNu9UN8EmkTc8ogWx/RtrY=; b=rw+0VMluTGJ92jUnHokriYTa4GP+yXEeGurl5VkxQJhc6SpnlIyH0hjZMAMwjaYb1f yXqROGpgNuKNVkkYCGoXQ3kS3f+kRNZzMcp+YWoZD8DCUa/2g7NzOB/oU7kN5maFuzl9 uflAGjL9vgjFV4tFPFK1zetB6uPaly6rFwzH09xOGNy58WniHcJ4MmYiBJNUti3ilfJs m7cBg5Hw+te5UGmrtlAcT4oT7Hjbq8XzVHNCEe8GtDdz9c1N8tKKsHxUKdpbgP3mhCqv cc/3ocxgFOitErsoPBU9xMribT5nsrL6/Y97nGnGhGph7N4Tz5nCfGZhtV6FQjaSMkX6 M+hQ== X-Gm-Message-State: AOJu0YwFor+p49DQa5KjlrmJBkY3SEm/6TKd7W+M6IM9dhLTfUTeuQSq MbzopXkKNjBxCl2vgRpFSPOTVMH+Fo+EgzTLy+TZHvpkQ6PGeffgUsI8E+rotbWe2MPZriecgpZ i8oMaje5aoBZXevYcyIMjNFsn9osQK2IQog== X-Gm-Gg: Acq92OESLS5lQwaS2g2XVV3eyPoC7G2iAMOLC68uGxkWA8mYB8mO2OwfgcW996OrkcI bJU8h3ex0WVdSV3kfZ978xNSXX2Trl3IG63ZVexvCj2hRttE7nEH9axrxbw2rpkfkiNtr3LIxBb 9OjVncBjfoq/xOOUWJ6e2//fux9r/v6ZDPUH+f/3OU9hE8yE1tckqEB/ApkU2tw4c7vYeJCbUy1 qcrtimJ/Pb3kTqmhgNmcnmBKPxXYVv2pqMbCbnzNPQ+Xek1cVN3sPahBUgFwJcjAGT7CW3LP1Uk XiVTAcyqWgjhy+8VT5NaQBplCPkTvrgNDeO4MOcl5w== X-Received: by 2002:a2e:a98f:0:b0:393:c6b5:993b with SMTP id 38308e7fff4ca-3992b2e1849mr16737321fa.24.1781333314021; Fri, 12 Jun 2026 23:48:34 -0700 (PDT) MIME-Version: 1.0 From: Raj Date: Sat, 13 Jun 2026 12:18:22 +0530 X-Gm-Features: AVVi8CfVw_TX9EOOneGhYk-lgLhikSN3JIKPjYg_lJNBFAg70Q9OOTW-MTrKdmo Message-ID: Subject: Size of /pgdata To: Pgsql-admin Content-Type: multipart/alternative; boundary="00000000000068ab8d06541cfbb8" List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --00000000000068ab8d06541cfbb8 Content-Type: text/plain; charset="UTF-8" Hi all, I am using 17.9 version. I see suddenly du -sh /pgdata/17 shows 930GB. Total allocated is 1TB. I checked the db size using \l+ and also pg_total_relation_size and size for particular db is 630GB. Ignoring postgres and template dbs as they are in KBs. Now where the remaining 300 comes from approximately..? I checked pg_wal and is 100gb..that is intended based on max_wal_size setting. Postgres logs also in MBs ..so ruling out that. Now 300 - 100 = 200gb approximately don't know where it comes from. So du -sh /base is approximately 830Gb whereas actual db size is 630gb as mentioned earlier. I took one big sample table which is 73GB, and using relfilenode(327683) I tried finding the underlying file size du -sh 327683* and able to find the total size the files occpuing and found 113gb.......so for one table itself it is 40Gb additional... I also checked the bloat of table using pgstatstuple and no bloat observed for this sample table Why we have so much increase of file size? How we can avoid or tune it? Is it about reallocating files and not being used fully? What's the solution? --00000000000068ab8d06541cfbb8 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hi all,

I am= using 17.9 version.=C2=A0

I see suddenly du -sh /pgdata/17 shows=C2=A0 930GB. Total allocated is 1= TB.

I checked the db siz= e using \l+ and also pg_total_relation_size and size for particular db is 6= 30GB. Ignoring postgres and template dbs as they are in KBs.

Now where the remaining 300 comes fro= m approximately..?

I che= cked pg_wal and is 100gb..that is intended based on max_wal_size setting.

Postgres logs also in MBs= ..so ruling out that.

N= ow 300 - 100 =3D 200gb=C2=A0 approximately don't know where it comes fr= om.

So du -sh /base is a= pproximately 830Gb whereas actual db size is 630gb as mentioned earlier.

I took one big sample tabl= e which is 73GB, and using relfilenode(327683) I tried finding the underlyi= ng file size du -sh 327683*=C2=A0 and able to find the total size the files= occpuing and found 113gb.......so for one table itself it is 40Gb addition= al...

I also checked the= bloat of table using pgstatstuple and no bloat observed for this sample ta= ble=C2=A0

Why we have so= much increase of file size? How we can avoid or tune it? Is it about reall= ocating files and not being used fully? What's the solution?




--00000000000068ab8d06541cfbb8--