pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Peter M. Groen <pgroen@osdev.nl>
To: srijith s <udbdoctor@gmail.com>
To: pgsql-admin@lists.postgresql.org
Subject: Re: After vacuum db size is increasing
Date: Mon, 16 Aug 2021 20:50:58 +0200
Message-ID: <0d8fcf46441c7ba47702bd7d886b1c419e6f73d4.camel@osdev.nl> (raw)
In-Reply-To: <7C3DCEF8-BBCF-4E92-B330-1D83121E638B@gmail.com>
References: <7C3DCEF8-BBCF-4E92-B330-1D83121E638B@gmail.com>

It is a misconception that VACUUM will decrease allocated diskspace. 
PG is allocating tablespace, used by data or not. If it needs more, it
will extend those. Downsize of this ( pun intended ) that tablespaces
normally *don't* shrink. You saying your database is only using 80Gb
but this is only 80Gb of *data*. That 80Gb is probably used within the
tablespace mentioned.

I don;t know the setup of your database but it sounds to me, your
tablespace is extended during the VACUUM operation for whatever
reason.. (Temporary space?) It seems odd to me that it "adds" the exact
amount of space as it was initially...
-- 
Open Systems Development B.V.
Peter M. Groen ( Managing Director )
Rooseveltstraat 18-P
2321 BM  Leiden
Mob   : +31 6 81 10 35 37
Email : peter@osdev.nl
Slype : peter_m_groen

On Mon, 2021-08-16 at 12:20 -0400, srijith s wrote:
> Hi Postgres Admins 
> 
> Any help is much appreciated . When i am running vacuum full, the
> database size is getting increased a lot, my database was around
> 100gb and when i did vacuum full on the large table ( which consume
> 95% of data in the database) , database size become 200+ gb , then i
> did a full vacuum on the database itself and that made the db grow to
> 300+gb 🙄 and filled my data drive .
> The large table size is showing only 80gb. 
> 
>  I am running Postgres on windows. Anybody know why its behaving like
> this 
> 
> Thanks in advance
> Regards
> Sri 
> 
> 
> 
> 
> 
> Sent from my iPhone
> 
> 






view thread (3+ messages)  latest in thread

Message-ID: <0d8fcf46441c7ba47702bd7d886b1c419e6f73d4.camel@osdev.nl>
Permalink:  ../0d8fcf46441c7ba47702bd7d886b1c419e6f73d4.camel@osdev.nl/
Also on:    postgresql.org/message-id/0d8fcf46441c7ba47702bd7d886b1c419e6f73d4.camel@osdev.nl

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-admin@postgresql.org
  Cc: pgroen@osdev.nl, udbdoctor@gmail.com, pgsql-admin@lists.postgresql.org
  Subject: Re: After vacuum db size is increasing
  In-Reply-To: <0d8fcf46441c7ba47702bd7d886b1c419e6f73d4.camel@osdev.nl>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox