ooni/sysadmin

Create a periodic database dump of the metadb

hellais opened this issue · 1 comments

As discussed in #272 (comment) we should periodically create a new full DB dump that we base the WAL increments from.

This may either be as a airflow task or a cronjob.

darkk commented

If that follows a pattern of cronjob instead of airflow task, I'd suggest to hook it's status to Pushgateway monitoring (like it's done for hellais-nas backup and WAL shipment that is a cronjob-style script controlled by postgres). Otherwise there is a risk of a silent cronjob rot.

Also WAL archive may be cleaned up after the dump. We should probably keep two latest snapshots and corresponding WAL. As WAL-based PITR is unavailable for [backup_start, backup_end] window given $backup, so two backups solve that issue as their windows do not overlap.