Postgres increase of configurations
pratoa
PROOP
2 months ago
I need to increase the following settings for my postgres template. How can we do that since a SELECT pg_reload_conf(); does not work
-- Connections (currently ~100, increase significantly)
ALTER SYSTEM SET max_connections = 500;
-- Memory allocation (from 280MB, use more)
ALTER SYSTEM SET shared_buffers = '8GB'; -- 25% of RAM
ALTER SYSTEM SET effective_cache_size = '24GB'; -- 75% of RAM
ALTER SYSTEM SET work_mem = '32MB'; -- 24GB / (500 connections × 1.5)
ALTER SYSTEM SET maintenance_work_mem = '2GB'; -- For VACUUM, CREATE INDEX
-- Query optimization
ALTER SYSTEM SET random_page_cost = 1.1; -- For SSD
ALTER SYSTEM SET effective_io_concurrency = 200; -- Multiple spindles
ALTER SYSTEM SET max_parallel_workers_per_gather = 4;
ALTER SYSTEM SET max_parallel_workers = 8;1 Replies
Status changed to Solved brody • 2 months ago
