Dear all,
I was reading again the documentation... “The archive command should generally de designed to refuse to overwrite any pre-existing archive file.”
This means it will keep writing logs to the folder specified forever, and without an intervention, the media will run out of space.
What do you guys do with regards to this situation, for example:
How to you clean up the old archived logs?
For example:
you archive your log files from your main Postgres server to a folder /mnt/pitr for example
You set your standby to pick the logs from /mnt/pitr, then it archives each log as it comes.
/mnt/pitr will fill up very quickly and run out of space if we don’t have a process to DELETE/ARCHIEVE older logs.
I guess the process which picks up the logs for the standby server, needs to take care of the logs, by deleting the older ones or by archiving them permanently?
How do you guys deal with this problem?
Thank you very much in advance
Best regards
Renato