Re: database size after a DELETE and VACUUM

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Jul 01, 2005 at 09:30:50AM -0400, Mike.Samson@xxxxxxxx wrote:
> 
> I would expect the database size to decrease after the VACUUM.

Note what the documentation says about VACUUM and recovering disk
space:

http://www.postgresql.org/docs/8.0/static/maintenance.html#VACUUM-FOR-SPACE-RECOVERY

"There are two variants of the VACUUM command.  The first form,
known as 'lazy vacuum' or just VACUUM, marks expired data in tables
and indexes for future reuse; it does not attempt to reclaim the
space used by this expired data immediately.  Therefore, the table
file is not shortened, and any unused space in the file is not
returned to the operating system.  This variant of VACUUM can be
run concurrently with normal database operations."

"The standard form of VACUUM is best used with the goal of maintaining
a fairly level steady-state usage of disk space.  If you need to
return disk space to the operating system you can use VACUUM FULL --
but what's the point of releasing disk space that will only have
to be allocated again soon?"

-- 
Michael Fuhr
http://www.fuhr.org/~mfuhr/


[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux