1 # -------------------------------
2 # PostgreSQL recovery config file
3 # -------------------------------
5 # Edit this file to provide the parameters that PostgreSQL needs to
6 # perform an archive recovery of a database, or to act as a replication
9 # If "recovery.conf" is present in the PostgreSQL data directory, it is
10 # read on postmaster startup. After successful recovery, it is renamed
11 # to "recovery.done" to ensure that we do not accidentally re-enter
12 # archive recovery or standby mode.
14 # This file consists of lines of the form:
18 # Comments are introduced with '#'.
20 # The complete list of option names and allowed values can be found
21 # in the PostgreSQL documentation.
23 #---------------------------------------------------------------------------
24 # ARCHIVE RECOVERY PARAMETERS
25 #---------------------------------------------------------------------------
29 # specifies the shell command that is executed to copy log files
30 # back from archival storage. The command string may contain %f,
31 # which is replaced by the name of the desired log file, and %p,
32 # which is replaced by the absolute path to copy the log file to.
34 # This parameter is *required* for an archive recovery, but optional
35 # for streaming replication.
37 # It is important that the command return nonzero exit status on failure.
38 # The command *will* be asked for log files that are not present in the
39 # archive; it must return nonzero when so asked.
41 # NOTE that the basename of %p will be different from %f; do not
42 # expect them to be interchangeable.
44 #restore_command = '' # e.g. 'cp /mnt/server/archivedir/%f %p'
47 # archive_cleanup_command
49 # specifies an optional shell command to execute at every restartpoint.
50 # This can be useful for cleaning up the archive of a standby server.
52 #archive_cleanup_command = ''
54 # recovery_end_command
56 # specifies an optional shell command to execute at completion of recovery.
57 # This can be useful for cleaning up after the restore_command.
59 #recovery_end_command = ''
61 #---------------------------------------------------------------------------
62 # RECOVERY TARGET PARAMETERS
63 #---------------------------------------------------------------------------
65 # By default, recovery will rollforward to the end of the WAL log.
66 # If you want to stop rollforward at a specific point, you
67 # must set a recovery target.
69 # You may set a recovery target either by transactionId, by name,
70 # or by timestamp. Recovery may either include or exclude the
71 # transaction(s) with the recovery target value (ie, stop either
72 # just after or just before the given target, respectively).
75 #recovery_target_name = '' # e.g. 'daily backup 2011-01-26'
77 #recovery_target_time = '' # e.g. '2004-07-14 22:39:00 EST'
79 #recovery_target_xid = ''
81 #recovery_target_inclusive = true
84 # If you want to recover into a timeline other than the "main line" shown in
85 # pg_control, specify the timeline number here, or write 'latest' to get
86 # the latest branch for which there's a history file.
88 #recovery_target_timeline = 'latest'
90 #---------------------------------------------------------------------------
91 # STANDBY SERVER PARAMETERS
92 #---------------------------------------------------------------------------
96 # When standby_mode is enabled, the PostgreSQL server will work as a
97 # standby. It will continuously wait for the additional XLOG records, using
98 # restore_command and/or primary_conninfo.
104 # If set, the PostgreSQL server will try to connect to the primary using this
105 # connection string and receive XLOG records continuously.
107 #primary_conninfo = '' # e.g. 'host=localhost port=5432'
110 # By default, a standby server keeps restoring XLOG records from the
111 # primary indefinitely. If you want to stop the standby mode, finish recovery
112 # and open the system in read/write mode, specify path to a trigger file.
113 # The server will poll the trigger file path periodically and start as a
114 # primary server when it's found.
118 #---------------------------------------------------------------------------
119 # HOT STANDBY PARAMETERS
120 #---------------------------------------------------------------------------
122 # Hot Standby related parameters are listed in postgresql.conf
124 #---------------------------------------------------------------------------