pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Michael G. Martin <michael@vpmonline.com>
To: pgsql-admin <pgsql-admin@postgresql.org>
Subject: Re: Postgres performance slowly gets worse over a month
Date: Wed, 24 Jul 2002 08:00:04 -0600
Message-ID: <3D3EB2E4.5000502@vpmonline.com> (raw)
References: <4.2.2.20020723110231.01daf8c0@ecint.ecinet.com>
	<1027448992.25561.25.camel@skymaster>
	<1027448282.15044.24.camel@sargao>
	<3D3DC06C.8010707@vpmonline.com>
	<015601c23303$58a63040$d60ffea9@GMENDOLA2>

  I believe, from a quick glance at the file vacuum.c, the first number 
is the total amount of free pages the database now occupies.  The second 
number is how much is actually available for new tuples to be created in.

--Michael

Gaetano Mendola wrote:

>"Michael G. Martin" <michael@vpmonline.com> wrote:
>  
>
>>Check this value in the postgresql.con file:
>>
>>max_fsm_pages = 100000
>>
>>I had the same problem with the db growing, index no longer being used,
>>despite vacuums each night.  Somewhere, there is a thread on this.
>>
>>Anyway, If you look at the vacuum stats each time your run vacuum, looks
>>to see how many pages are being updated between vacuums--i looked at the
>>removed x tuples in y pages value.  Then, set this value to be greater
>>than the number of pages changed between vacuums.  If more pages are
>>being updated between vacuums than what max_fsm_pages allows, the extra
>>pages won't be marked to be re-used--from what I understand.  This then
>>results in the db growing and the optimizer starts to chose full table
>>scans since the db spans so many pages on the disk--at least this is
>>what happened in my db.
>>    
>>
>
>
>Can you explain me this line that I obatin in the log
>after a vacuum analyze ?
>
> --Relation ua_user_data_exp--
>2002-07-21 05:00:02 [28492]  DEBUG:  Pages 1402: Changed 2, reaped 1192,
>Empty 0, New 0; Tup 4277: Vac 16207, Keep/VTL 0/0, Crash 0, UnUsed 1, MinLen
>393, MaxLen 680; Re-using: Free/Avail. Space 9148944/9141356;
>EndEmpty/Avail. Pages 0/1191. CPU 0.00s/0.03u sec.
>
>I'm wondering about "Re-using: Free/Avail. Space 9148944/9141356"
>
>
>Ciao
>Gaetano
>  
>

view thread (31+ messages)  latest in thread

Message-ID: <3D3EB2E4.5000502@vpmonline.com>
Permalink:  ../3D3EB2E4.5000502@vpmonline.com/
Also on:    postgresql.org/message-id/3D3EB2E4.5000502@vpmonline.com

 · 

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 from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-admin@postgresql.org
  Cc: michael@vpmonline.com
  Subject: Re: Postgres performance slowly gets worse over a month
  In-Reply-To: <3D3EB2E4.5000502@vpmonline.com>
  References: <4.2.2.20020723110231.01daf8c0@ecint.ecinet.com> <1027448992.25561.25.camel@skymaster> <1027448282.15044.24.camel@sargao> <3D3DC06C.8010707@vpmonline.com> <015601c23303$58a63040$d60ffea9@GMENDOLA2> <3D3EB2E4.5000502@vpmonline.com>

* 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