# ============================================= # PostgreSQL Configuration File (postgresql.conf) # ============================================= # # This configuration file controls the behavior of the PostgreSQL database server. # # Most changes require a restart or reload of the PostgreSQL service to take effect. # Run `pg_ctl reload` or restart the service via your system's init system. # # PostgreSQL reads configuration files in the following order: # 1. postgresql.conf – Main configuration file (this file) # 2. postgresql.auto.conf – Auto-generated by ALTER SYSTEM (do not edit manually) # 3. Included files via `include` or `include_dir` # # To learn more, visit: https://www.postgresql.org/docs/current/runtime-config.html # # ============================================= # Connection Settings # ============================================= # Listen on all network interfaces (0.0.0.0/::) for external connections. listen_addresses = '*' # Default port number for PostgreSQL. port = 5432 # Maximum number of concurrent client connections. # Increase this value based on application load and available resources. max_connections = 500 # ============================================= # Memory Settings # ============================================= # Size of the shared memory buffer pool. # Recommended: ~25% of system RAM. shared_buffers = 256MB # Memory available for internal sort operations and hash tables. # Applies per sort or join operation, not per query. work_mem = 4MB # Memory reserved for maintenance operations such as VACUUM, CREATE INDEX, etc. maintenance_work_mem = 64MB # ============================================= # Logging Settings # ============================================= # Enable capturing of logs to files. logging_collector = on # Directory where log files will be saved. log_directory = 'log' # Naming pattern for log files (timestamped). log_filename = 'postgresql-%Y-%m-%d_%H%M%S.log' # Log all statements: 'none', 'ddl', 'mod', or 'all'. # Set to 'none' to avoid verbose logging in production. log_statement = 'none' # Minimum severity of SQL errors to be logged. # Values: debug5 to fatal, or 'panic'. log_min_error_statement = error # ============================================= # Localization and Timezone # ============================================= # Set the preferred date and time format. # 'iso' for ISO 8601, 'mdy' for month-day-year. datestyle = 'iso, mdy' # Set server time zone. timezone = 'Europe/Amsterdam' # ============================================= # Full Text Search # ============================================= # Default language configuration for full-text search. # Affects stemming, stop words, etc. default_text_search_config = 'pg_catalog.dutch' # ============================================= # Security and Access Control # ============================================= # Authentication settings are defined separately in pg_hba.conf. # Ensure that file is configured correctly to allow expected access. # ============================================= # Including Additional Configuration Files # ============================================= # You may include other configuration files or directories like this: # include = 'custom_settings.conf' # include_dir = 'conf.d'