on
is recommended. Disable only if you experience suboptimal plans for complex queries and want to force exhaustive search. For most workloads with queries involving 12+ tables, GEQO provides significantly better planning performance with minimal plan quality trade-offs.geqo_pool_size
, geqo_generations
, and other parameters to provide a balanced configuration.5
provides a good balance. Increase to 7-10
for data warehouse environments where planning time is less critical than execution time. Decrease to 2-3
for OLTP systems where fast planning is essential. Monitor planning time versus execution time to find the optimal balance.0
(auto-set based on geqo_effort
). If setting manually, start with 100-200
generations. Increase for very complex queries (500+) if planning time is acceptable. Monitor the trade-off between additional planning time and improved execution time.0
(auto-set based on geqo_effort
). If setting manually, use 50-200
individuals. Larger values (300-500) may help for extremely complex queries but significantly increase planning time. Scale based on the number of tables in your typical complex queries.0
(uses current time, making behavior non-deterministic). Set to a fixed value (e.g., 0.5
) when debugging plan instability issues. For production, the default is usually best as it provides variety in plan exploration.2.0
is generally effective. Increase to 3.0-4.0
for faster convergence when you trust the initial population quality. Decrease to 1.5-2.0
for more diverse exploration in complex search spaces.12
is reasonable for most workloads. For OLTP systems with simple queries, consider increasing to 15-20
. For data warehouses with complex analytics, decrease to 8-10
to engage GEQO earlier. Monitor planning times for queries near your threshold.Start your journey toward a healthier PostgreSQL with pghealth.
You can explore all features immediately with a free trial β no installation required.
π Start Free Trial