Re: possible vacuum improvement?

Поиск
Список
Период
Сортировка
От Rod Taylor
Тема Re: possible vacuum improvement?
Дата
Msg-id 1031054275.21926.26.camel@jester
обсуждение исходный текст
Ответ на Re: possible vacuum improvement?  ("Mario Weilguni" <mweilguni@sime.com>)
Список pgsql-hackers
On Tue, 2002-09-03 at 03:36, Mario Weilguni wrote:
> > gets updated for each transaction but log table is just an insert. So
> rather
> > than vacumming entire db, just doing 'vacuum analyze accounts' give me
> almost
> > same results.
> >
> 
> That is not really practicable, one datebase has 107 tables, and making a
> cron job
> with 107 vacuum calls is completly out of question and very error prone
> anyway.

So...  Write a script which does something like:

skiptables = "'skipme' 'andme'"
tables = `psql -c 'SELECT relname from pg_class where relname not in
(${skiptables})' template1`

for tab in ${tables} ; do vacuumdb -t ${tab}
done


Fill in the holes and your done -- get the right pg_class type, handle
schemas appropriately, etc.



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

Предыдущее
От: Karel Zak
Дата:
Сообщение: Re: Memory management question
Следующее
От: "Marc G. Fournier"
Дата:
Сообщение: Re: HISTORY file