Re: storage calculations

Поиск
Список
Период
Сортировка
От Peter Eisentraut
Тема Re: storage calculations
Дата
Msg-id Pine.LNX.4.56.0307301424060.1171@krusty.credativ.de
обсуждение исходный текст
Ответ на Re: storage calculations  (pgboy@guthrie.charm.net)
Список pgsql-admin
pgboy@guthrie.charm.net writes:

> sorry, when i referred to "disk space used" i meant the actual amount
> used by live rows. if i insert 1000 rows then delete 999 of them, the
> disk file will be the size of the 100 row container (make that 1000, not
> 100 - i cannot backspace here) until i do a "vacuum full" - which does a
> table lock, which is a bad thing.

The task that you originally described was that you want to monitor when
the disk is getting full.  For that task, you need to take into account
the actual size of the data on disk, not the size after a "vacuum full"
which you say you do not want to execute.  Basing a disk full monitor on
hypothetical sizes sounds pretty useless.

> given that, i'd like to try to be able to calculate the number of
> bytes a row uses given its schema. i've seen this kind of
> documentation for other dbs, i just cannot seem to find it
> in the postgresql docs.

There is some information about that in the FAQ, but keep in mind that
rows may be compressed or moved to secondary storage automatically.

--
Peter Eisentraut   peter_e@gmx.net


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

Предыдущее
От: "John P. Looney"
Дата:
Сообщение: Re: Postgres db corrupted ?
Следующее
От: Robert Treat
Дата:
Сообщение: Re: 7.3.4 RPM ready for RH 7.1 and RH 7.2