# Optional configuration file settings

This section documents a subset of optional configuration settings; for a full for a full and annotated view of all configuration options see the see the sample repmgr.conf file

`config_directory` (string)

  If PostgreSQL configuration files are located outside the data directory, specify the directory where the main `postgresql.conf` file is located.

  This enables explicit provision of an external configuration file directory, which if set will be passed to `pg_ctl` as the `-D` parameter. Otherwise `pg_ctl` will default to using the data directory, which will cause some operations to fail if the configuration files are not present there.

  This is implemented primarily for feature completeness and for development/testing purposes. Users who have installed &repmgr; from a package should not rely on to stop/start/restart PostgreSQL, instead they should set the appropriate `service_..._command` for their operating system. For more details see .

`replication_user` (string)

  PostgreSQL user to make replication connections with. If not set defaults, to the user defined in .

`replication_type` (string)

  Must be `physical` (the default).

`location` (string)

  An arbitrary string defining the location of the node; this is used during failover to check visibility of the current primary node.

  For more details see .

`use_replication_slots` (boolean)

  Whether to use physical replication slots.

  When using replication slots, `max_replication_slots` should be configured for at least the number of standbys which will connect to the primary.

`ssh_options` (string)

  Options to append to the `ssh` command when executed by &repmgr;.

  We recommend adding `-q` to suppress any superfluous SSH chatter such as login banners, and also an explicit `ConnectTimeout` value, e.g.:

      ssh_options='-q -o ConnectTimeout=10'

`pg_bindir` (string)

  Path to the PostgreSQL binary directory (location of pg_ctl, pg_basebackup etc.). Only required if these are not in the system `PATH`.

  When &repmgr; is executed via SSH (e.g. when running `repmgr standby switchover`, `repmgr cluster matrix` or `repmgr cluster crosscheck`, or if it is executed as cronjob), a login shell will not be used and only the default system `PATH` will be set. Therefore it's recommended to set `pg_bindir` so &repmgr; can correctly invoke binaries on a remote system and avoid potential path issues.

  Debian/Ubuntu users: you will probably need to set this to the directory where pg_ctl is located, e.g. `/usr/lib/postgresql/9.6/bin/`.

  NOTE: `pg_bindir` is only used when &repmgr; directly executes PostgreSQL binaries; any user-defined scripts must be specified with the full path.

See the sample repmgr.conf file for a full and annotated view of all configuration options.