Re: archive folder maintenance

Поиск
Список
Период
Сортировка
От Payal Singh
Тема Re: archive folder maintenance
Дата
Msg-id CANUg7LAkmnKkLgZ7PFiAse0Otcr81SORteRYigR=4=JNq_9gdA@mail.gmail.com
обсуждение исходный текст
Ответ на archive folder maintenance  (Keith Ouellette <Keith.Ouellette@Airgas.com>)
Ответы Re: archive folder maintenance  (Keith Ouellette <Keith.Ouellette@Airgas.com>)
Список pgsql-novice
Is this a standalone server? What is the value of archive_timeout?
 
It is generally safe to delete WAL files older than a day or two. More specifically, all WAL files older than the latest base backup are safe to selete. A simple bash script will do in this case. 

You can also have alook at http://www.postgresql.org/docs/9.2/static/pgarchivecleanup.html tool which you can straightaway use. 


Payal Singh,
OmniTI Computer Consulting Inc.
Junior Database Administrator,
Phone: 240.646.0770 x 253


On Tue, Jan 21, 2014 at 9:16 PM, Keith Ouellette <Keith.Ouellette@airgas.com> wrote:

We are running PostgreSQL 9.1 with WAL. I am noticing the archive directory just keeps growing. It is currently at 392GB. What is the proper maintenance to keep that under control? It does not seem necessary to have that much archived. We are doing regular backups (pgdump). Any suggestions. The WAL configuration is the following:

 

wal_level = hot_standby

archive_mode = on

archive_command = 'cp %p /opt/PostgreSQL/9.1/data/archive/%f'

max_wal_senders = 2

wal_keep_segments = 1000  << I also think this is unnecessary as well should be much less in my opinion but shouldn't this deep 1000 16MB WAL files or 16GB?

 

 

Any guidance would be greatly appreciated

 

Thanks,

Keith


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

Предыдущее
От: Keith Ouellette
Дата:
Сообщение: archive folder maintenance
Следующее
От: Keith Ouellette
Дата:
Сообщение: Re: archive folder maintenance