Tuning the Mirror Database
The default configuration settings for the mirror database are appropriate when data volumes are relatively small or infrequently mirrored. When a lot of scenario data is being mirrored, the size of the database on disk can grow to be much larger than the actual amount of mirrored data being stored.
Tuning the database configuration settings can help to keep the size of the mirror database under control.
PostgreSQL cleans out old table data in the background in a process called auto-vacuuming. By default, it is configured to do this slowly, with minimal impact on system performance. If data is being inserted into a table faster than it is being vacuumed, the size of the table on disk will grow.
The rate of auto-vacuuming is controlled by several configuration settings described in:
https://www.postgresql.org/docs/9.5/static/routine-vacuuming.html#autovacuum. Specifically, reducing the
autovacuum_vacuum_cost_delay setting in
postgresql.conf will cause auto-vacuuming to run more quickly to offset an increased rate of mirror data creation.
![]() |
Note Reducing this setting will enable auto-vacuuming to consume more system resources, which may have an impact on other processes running on the machine.
|