Re: Autovaccum

Поиск
Список
Период
Сортировка
От Shane Ambler
Тема Re: Autovaccum
Дата
Msg-id 45706101.8040909@007Marketing.com
обсуждение исходный текст
Ответ на Autovaccum  ("Ezequias Rodrigues da Rocha" <ezequias.rocha@gmail.com>)
Список pgsql-sql
Ezequias Rodrigues da Rocha wrote:
> Could you tell me if only this both options are ok (attach) ?
> 
> If I don't mark the interval of vacuuns what will be the interval of
> each vacuum ?

The default settings may be fine for you, it depends a bit on how many 
insert/updates you get in a given time frame.

http://www.postgresql.org/docs/8.1/interactive/runtime-config-autovacuum.html
will give a definition of each parameter that can be set.

http://www.postgresql.org/docs/8.1/interactive/maintenance.html#AUTOVACUUM
will explain in more detail.

Basically every autovacuum_naptime seconds autovacuum looks at estimates 
of how much the database has changed since the last run. If the amount 
of change is greater than the thresholds determined from the other 
settings then a vacuum/analyze will be done.

If you have 100 records added/updated per day then you may only need it 
to run 1 or 2 times a day using smaller thresholds.

If you are adding 10,000 records an hour then you will want it to run 
more often.


> 2006/11/30, Shane Ambler <pgsql@007marketing.com>:
>> Alvaro Herrera wrote:
>> > Ezequias Rodrigues da Rocha wrote:
>> >> Hi list,
>> >>
>> >> I would like to know if it is necessary to set my database to
>> >> autovaccum if the intent of my DB Manager is do not make any deletion
>> >> in any time.
>> >>
>> >> If there is no deletions why autovaccum ok ?
>>  >
>> > You need to vacuum from time to time anyway, even if you don't delete
>> > anything.  The easiest way to do it is let autovacuum do it for you.
>> >
>>
>> One thing that vacuum/autovacuum does is mark space used by deleted rows
>> to be reused. Without deletes this won't be necessary in table data
>> files. But when you update a record an index may also be updated and
>> have the same effect within the index storage space.
>>
>> There are other things that vacuum does to keep your database running
>> optimally. One is to update planner statistics about how many rows are
>> in each table which effects the query planning and optimizing.
>>
>> Without deletes a plain vacuum won't achieve a great deal, but a regular
>> VACUUM ANALYZE (as done by autovacuum) will make a difference to the
>> performance of your database.
>>
>> If no data in your db changes then you won't have to bother vacuuming.
>>
>> -- 
>>
>> Shane Ambler
>> pgSQL@007Marketing.com
>>
>> Get Sheeky @ http://Sheeky.Biz
>>
> 
> 


-- 

Shane Ambler
pgSQL@007Marketing.com

Get Sheeky @ http://Sheeky.Biz


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

Предыдущее
От: "Rajesh Kumar Mallah"
Дата:
Сообщение: calling elog possibly causing problem in DirectFunctionCall1
Следующее
От: Tom Lane
Дата:
Сообщение: Re: calling elog possibly causing problem in DirectFunctionCall1