]> git.openstreetmap.org Git - chef.git/blob - cookbooks/postgresql/templates/default/postgresql.conf.erb
Install ipmitool on machines with the ipmi_si module loaded
[chef.git] / cookbooks / postgresql / templates / default / postgresql.conf.erb
1 # DO NOT EDIT - This file is being maintained by Chef
2
3 #------------------------------------------------------------------------------
4 # FILE LOCATIONS
5 #------------------------------------------------------------------------------
6
7 data_directory = '/var/lib/postgresql/<%= @version %>/main'
8 hba_file = '/etc/postgresql/<%= @version %>/main/pg_hba.conf'
9 ident_file = '/etc/postgresql/<%= @version %>/main/pg_ident.conf'
10 external_pid_file = '/var/run/postgresql/<%= @version %>-main.pid'
11
12 #------------------------------------------------------------------------------
13 # CONNECTIONS AND AUTHENTICATION
14 #------------------------------------------------------------------------------
15
16 # - Connection Settings -
17
18 <% if @settings[:listen_addresses] || @defaults[:listen_addresses] -%>
19 listen_addresses = '<%= @settings[:listen_addresses] || @defaults[:listen_addresses] %>'
20 <% end -%>
21 port = <%= @settings[:port] || @defaults[:port] %>
22 max_connections = <%= @settings[:max_connections] || @defaults[:max_connections] %>
23 unix_socket_directory = '/var/run/postgresql'
24
25 # - Security and Authentication -
26
27 ssl = true
28 ssl_renegotiation_limit = 0
29
30 #------------------------------------------------------------------------------
31 # RESOURCE USAGE (except WAL)
32 #------------------------------------------------------------------------------
33
34 # - Memory -
35
36 shared_buffers = <%= @settings[:shared_buffers] || @defaults[:shared_buffers] %>
37 temp_buffers = <%= @settings[:temp_buffers] || @defaults[:temp_buffers] %>
38 work_mem = <%= @settings[:work_mem] || @defaults[:work_mem] %>
39 maintenance_work_mem = <%= @settings[:maintenance_work_mem] || @defaults[:maintenance_work_mem] %>
40 max_stack_depth = <%= @settings[:max_stack_depth] || @defaults[:max_stack_depth] %>
41
42 #------------------------------------------------------------------------------
43 # WRITE AHEAD LOG
44 #------------------------------------------------------------------------------
45
46 # - Settings -
47
48 wal_level = <%= @settings[:wal_level] || @defaults[:wal_level] %>
49 fsync = <%= @settings[:fsync] || @defaults[:fsync] %>
50 synchronous_commit = <%= @settings[:synchronous_commit] || @defaults[:synchronous_commit] %>
51 wal_buffers = <%= @settings[:wal_buffers] || @defaults[:wal_buffers] %>
52 wal_writer_delay = <%= @settings[:wal_writer_delay] || @defaults[:wal_writer_delay] %>
53 commit_delay = <%= @settings[:commit_delay] || @defaults[:commit_delay] %>
54
55 # - Checkpoints -
56
57 checkpoint_segments = <%= @settings[:checkpoint_segments] || @defaults[:checkpoint_segments] %>
58 checkpoint_timeout = <%= @settings[:checkpoint_timeout] || @defaults[:checkpoint_timeout] %>
59 checkpoint_completion_target = <%= @settings[:checkpoint_completion_target] || @defaults[:checkpoint_completion_target] %>
60
61 # - Archiving -
62
63 archive_mode = <%= @settings[:archive_mode] || @defaults[:archive_mode] %>
64 <% if @settings[:archive_command] || @defaults[:archive_command] -%>
65 archive_command = '<%= @settings[:archive_command] || @defaults[:archive_command] %>'
66 <% end -%>
67
68 #------------------------------------------------------------------------------
69 # REPLICATION
70 #------------------------------------------------------------------------------
71
72 # - Sending Server(s) -
73
74 max_wal_senders = <%= @settings[:max_wal_senders] || @defaults[:max_wal_senders] %>
75
76 # - Standby Servers -
77
78 hot_standby = <%= @settings[:hot_standby] || @defaults[:hot_standby] %>
79 hot_standby_feedback = <%= @settings[:hot_standby_feedback] || @defaults[:hot_standby_feedback] %>
80
81 #------------------------------------------------------------------------------
82 # QUERY TUNING
83 #------------------------------------------------------------------------------
84
85 # - Planner Cost Constants -
86
87 random_page_cost = <%= @settings[:random_page_cost] || @defaults[:random_page_cost] %>
88 cpu_tuple_cost = <%= @settings[:cpu_tuple_cost] || @defaults[:cpu_tuple_cost] %>
89 effective_cache_size = <%= @settings[:effective_cache_size] || @defaults[:effective_cache_size] %>
90
91 #------------------------------------------------------------------------------
92 # ERROR REPORTING AND LOGGING
93 #------------------------------------------------------------------------------
94
95 # - When to Log -
96
97 log_min_duration_statement = <%= @settings[:log_min_duration_statement] || @defaults[:log_min_duration_statement] %>
98
99 # - What to Log -
100
101 log_line_prefix = '%t '
102
103 #------------------------------------------------------------------------------
104 # AUTOVACUUM PARAMETERS
105 #------------------------------------------------------------------------------
106
107 autovacuum_max_workers = <%= @settings[:autovacuum_max_workers] || @defaults[:autovacuum_max_workers] %>
108
109 #------------------------------------------------------------------------------
110 # CLIENT CONNECTION DEFAULTS
111 #------------------------------------------------------------------------------
112
113 # - Locale and Formatting -
114
115 datestyle = 'iso, dmy'
116 lc_messages = 'en_GB.UTF-8'
117 lc_monetary = 'en_GB.UTF-8'
118 lc_numeric = 'en_GB.UTF-8'
119 lc_time = 'en_GB.UTF-8'
120 default_text_search_config = 'pg_catalog.english'