Re: Unused item pointers - can someone explain? - Mailing list pgsql-general

From Peter Childs
Subject Re: Unused item pointers - can someone explain?
Date
Msg-id a2de01dd0711230123jf6dcae3s80f2c67e66e0680e@mail.gmail.com
Whole thread Raw
In response to Unused item pointers - can someone explain?  (Elmer <sebastian.franek@gmail.com>)
List pgsql-general


On 21/11/2007, Elmer <sebastian.franek@gmail.com> wrote:
Hello,

I vacuumed one of my database tables. In vacuum output I saw the
following information about unused item pointers:

There were 19310 unused item pointers.

As I understand It means that my table's file consists 19310 free
tuple pointers.

After some minutes I run vacuum again. It was quite unexpected for me
that number of unused item pointers was increased to 19351. I thought
unused item pointers are used in first place when new tuples versions
are created but this example makes me think I am wrong. Can someone
explain this to me?


Yes, however....

found x removable

have just been found and are now unused, so on the next run this number will be added to the unused unless they get used again in the mean time.

The number ie the unused is the number of tuples left in the free space map unused since the last vacuum. If its high it may be worth clustering or running vacuum full but only if you don't think you table will never or unlikely to grow (insert) or change (update) by less than that number of records before you next run vacuum.

Generally only worry if the number is very very high (over 10000).

The best way of understanding the numbers is to run vacuum at regular intervals and compare the output.

Peter.

pgsql-general by date:

Previous
From: Greg Smith
Date:
Subject: Re: Requesting for a pgadmin3-1.8.0 RPM for SL4
Next
From: "Peter Childs"
Date:
Subject: Re: Primary Key