Re: [HACKERS] Error "vacuum pg_proc"

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: [HACKERS] Error "vacuum pg_proc"
Дата
Msg-id 12358.946050770@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Error "vacuum pg_proc"  (Mateus Cordeiro Inssa <mateus@ifnet.com.br>)
Ответы Re: [HACKERS] Error "vacuum pg_proc"  (Tom Lane <tgl@sss.pgh.pa.us>)
Re: [HACKERS] Error "vacuum pg_proc"  (Mateus Cordeiro Inssa <mateus@ifnet.com.br>)
Список pgsql-hackers
Mateus Cordeiro Inssa <mateus@ifnet.com.br> writes:
>   I got this error vacuuming pg_proc:
> ERROR:  _bt_endpoint: leftmost page (20) has not leftmost flag

Hmm, I wonder if this could be yet another manifestation of the problems
that btree indexes have with oversized key values.  Do you have any
procedures with long definitions?  "Long" in this context means over
about 4K.  If you're not sure, tryselect proname from pg_proc where length(prosrc) > 4000;

If you do, try breaking them up into smaller procedures.  You might have
to dump and rebuild the database to get rid of the corruption in
pg_proc's index, though.

The reason this is an issue is that btree wants to be able to store at
least two index tuples per disk page, so it has problems with indexing
values over half-a-page-less-overhead.  I'm not sure exactly what the
critical size is, but it is somewhere around 4000 bytes.  And pg_proc
has an index on the prosrc field.

The prosrc index is actually completely unnecessary, so we've removed
it for 7.0.  Work is in progress to fix the tuple-size problem as well,
but that will probably take longer.
        regards, tom lane


В списке pgsql-hackers по дате отправления:

Предыдущее
От: Thomas Lockhart
Дата:
Сообщение: Re: [HACKERS] T-O-A-S-T meaning
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: [HACKERS] Source code format votes