Skip site navigation (1) Skip section navigation (2)

Re: [HACKERS] Re: pgsql: Fix free space map to correctly track the total amount of FSM

From: Decibel! <decibel(at)decibel(dot)org>
To: Tatsuo Ishii <ishii(at)postgresql(dot)org>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, PostgreSQL-development list <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: [HACKERS] Re: pgsql: Fix free space map to correctly track the total amount of FSM
Date: 2007-10-03 00:17:39
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-committerspgsql-hackers
Dropping -committers.

On Oct 2, 2007, at 10:37 AM, Tatsuo Ishii wrote:
>> Tatsuo Ishii <ishii(at)postgresql(dot)org> writes:
>>> Sorry for replying to very old message. But... it seems this was not
>>> backported to 8.1 or earlier.
>> Since it involved a change in the FSM API, it didn't seem reasonable
>> to back-patch it.
> So for those versions of PostgreSQL the only way to know the
> appropriate FSM pages is change FSM-restart postmaster-do vacuum cycle
> until vacuum reports the same number of "total page needed"?

That's the only easy way I know of, but there is something that might  
make life easier if you're using autovacuum... take SELECT sum 
(relpages) FROM pg_class and multiply that by  
autovacuum_vacuum_scale_factor. If autovac is doing a reasonable job  
of keeping up, that should be a maximum of what you'd need in the FSM.

Hrm... what about adding output to vacuum verbose that indicates how  
many pages in a relation have free space? That would allow something  
like pgfouine to see how many FSM pages were needed. It would also  
make it easier to identify relations that could stand a vacuum full/ 
reindex/cluster (though you'd also want to know something like  
average free space per page).
Decibel!, aka Jim C. Nasby, Database Architect  decibel(at)decibel(dot)org
Give your computer some brain candy! Team #1828

In response to


pgsql-hackers by date

Next:From: Jeff FrostDate: 2007-10-03 00:20:08
Subject: Why does the sequence skip a number with generate_series?
Previous:From: Hannes EderDate: 2007-10-02 22:58:29
Subject: Re: Latest ecpg patch broke MSVC build

pgsql-committers by date

Next:From: Alvaro HerreraDate: 2007-10-03 01:07:54
Subject: Re: Re: [COMMITTERS] pgsql: Fix free space map tocorrectly track the total amount of FSM
Previous:From: Neil ConwayDate: 2007-10-02 22:01:03
Subject: pgsql: Fix a compiler warning on Win32.

Privacy Policy | About PostgreSQL
Copyright © 1996-2018 The PostgreSQL Global Development Group