Re: Determine dead tuples size

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Determine dead tuples size
Дата
Msg-id 6304.1174055349@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Determine dead tuples size  (Alexey Romanchuk <aromanchuk@swsoft.com>)
Список pgsql-performance
Alexey Romanchuk <aromanchuk@swsoft.com> writes:
> When i try to sum all size (live, dead and free) the sum is not equal
> total size. For this table 206555428 + 3380295 + 13896816 = 223832539.
> The difference between total and sum is 9410085. It is near 5%.

pgstattuple is a bit simplistic: it doesn't count the page headers or
item pointers at all.  It looks to me like it also fails to consider
the effects of alignment padding --- if a tuple's length is shown as
63, that's what it counts, even though the effective length is 64.
(This might not be a problem in practice --- I'm not sure if the stored
t_len has always been maxaligned or not.)

            regards, tom lane

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

Предыдущее
От: "Joshua D. Drake"
Дата:
Сообщение: Re: Postgres batch write very slow - what to do
Следующее
От: cedric
Дата:
Сообщение: unsubscribe