Обсуждение: autovacuum questions

Поиск
Список
Период
Сортировка

autovacuum questions

От
Isabella Ghiurea
Дата:
Hello Gurus,
I'm new to PG , running PG 8.3 on Linux and reading trough docs  is
mentioned that in PG vers 8.3  an AUTO vacuum process   has been
implemented which will run
full vacuum  on  all user and system tables + analyze  and there is  NO
need fro DBA  to schedule a crontab job to run this  maintenance jobs .
If this is true , here are my questions :
Would like to know from your experience is this automated process
sufficient and reliable in a warehouse database , can I rely only  on
this  internal  process ?
How can I see when the job has been run or completed by PG ?
I have configure track_count=true, what values should I go for
autovacuum_naptime  from your experience?

Isabella


Re: autovacuum questions

От
"Rafael Domiciano"
Дата:
Hello there,

Yes, the autovacuum is set on by default on the PG 8.3.
The vacuum is not full, to run a full vacuum you need to set a cron job; better to run at the night.
I don't set autovacuum on the production databases, only in the Slony's slave machines and in the developmente machine.
For autovacuum settings you need to set and see if it's ok for you.
to see if the vacuum is running you can use the command "ps axf | grep postgres" on the linux server. Sometimes autovacuum is so fast that you even notice him.

I hope that I helped

Best Regards,

Rafael Domiciano

2008/10/31 Isabella Ghiurea <isabella.ghiurea@nrc-cnrc.gc.ca>
Hello Gurus,
I'm new to PG , running PG 8.3 on Linux and reading trough docs  is mentioned that in PG vers 8.3  an AUTO vacuum process   has been implemented which will run
full vacuum  on  all user and system tables + analyze  and there is  NO need fro DBA  to schedule a crontab job to run this  maintenance jobs . If this is true , here are my questions :
Would like to know from your experience is this automated process sufficient and reliable in a warehouse database , can I rely only  on this  internal  process ?
How can I see when the job has been run or completed by PG ?
I have configure track_count=true, what values should I go for autovacuum_naptime  from your experience?

Isabella


--
Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin

Re: autovacuum questions

От
Alvaro Herrera
Дата:
Rafael Domiciano escribió:

> The vacuum is not full, to run a full vacuum you need to set a cron job;
> better to run at the night.

Doing VACUUM FULL on crontab is rarely a good idea.  If you find
yourself in a situation where you need VACUUM FULL, then you've not
tuned regular vacuum appropriately.

--
Alvaro Herrera                                http://www.CommandPrompt.com/
The PostgreSQL Company - Command Prompt, Inc.

Re: autovacuum questions

От
"Scott Marlowe"
Дата:
On Fri, Oct 31, 2008 at 10:02 AM, Alvaro Herrera
<alvherre@commandprompt.com> wrote:
> Rafael Domiciano escribió:
>
>> The vacuum is not full, to run a full vacuum you need to set a cron job;
>> better to run at the night.
>
> Doing VACUUM FULL on crontab is rarely a good idea.  If you find
> yourself in a situation where you need VACUUM FULL, then you've not
> tuned regular vacuum appropriately.

There are some use cases where vacuum full is appropriate.  But
they're rare.  And they're usually better off being added to whatever
script is doing the thing that causes the database to need vacuum
full.  Certain batch processing or data loading processes need vacuum
full and or reindex when finishing.

But the common thought process on vacuum full for most people is "If
vacuum is good, vacuum full must be even better!" which is just wrong.