Re: Removing archived wal files on Master

Поиск
Список
Период
Сортировка
От Shreeyansh Dba
Тема Re: Removing archived wal files on Master
Дата
Msg-id CAGDYbUPeRHnb73MA2C39kEJfPByQT4YiRhvG0bee86=_ygfXpA@mail.gmail.com
обсуждение исходный текст
Ответ на Removing archived wal files on Master  (Michael King <michaelbking@hotmail.com>)
Ответы Re: Removing archived wal files on Master
Список pgsql-admin
Hi Michael,

I suspect that your DB parameters are set to default and database is not running in an archive mode as archive_mode = off , I believe PostgreSQL won't write archives when archive_mode is off and  WAL archival cannot be enabled when wal_level is "minimal".

I assume the existing 200GB worth of archived wal files are old where you can verify by checking the timestamp of the Wal files and remove.

If you want to disable/enable archive_command you can simply comment/uncomment parameter and reload the server to affect but for 
enabling archive_mode = on server required a restart.

Thanks & Regards,
Shreeyansh DBA Team
www.shreeyansh.com


On Fri, Feb 22, 2019 at 4:49 PM Michael King <michaelbking@hotmail.com> wrote:
Hi, 
I recently acquired a legacy server. This is running Postgresql 9.3 on Ubuntu 16.04. 
There is around 200GB worth of archived wal files (~12,500 files)  located on /var/lib/postgresql/9.3/main/archive. 
I have checked and can confirm that this is a standalone server without any Replication setup and no secondary/slave server talking to it.

Checking the /etc/postgresql/9.3/main/postgresql.conf file (write ahead log section), shows the following:
wal_level = minimal
archive_mode = off
archive_command = 'test ! -f /var/lib/postgresql/9.3/main/archive/%f && cp -i %p /var/lib/postgresql/9.3/main/archive/%f </dev/null'

Replication section shows all default values.

Could you please advice how I can cleanup all of these 200GB worth of files.
I've searched through numerous postgresql books/blogs/articles which all have very good advise on how to setup wal archiving but unfortunately not on how to disable it.

Kind regards,
Michael

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

Предыдущее
От: Michael King
Дата:
Сообщение: Re: Removing archived wal files on Master
Следующее
От: Michael King
Дата:
Сообщение: Re: Removing archived wal files on Master