]> git.8kb.co.uk Git - slony-i/pgbouncer_follower/blobdiff - README.md
When we repoint an rw server it is perhaps better to force clients to reconnect with...
[slony-i/pgbouncer_follower] / README.md
index e98d8e977a172ba9e2fbf406f39514ed976d75a2..83577801db0ddfba352be6d01eeb4e4b017c1294 100644 (file)
--- a/README.md
+++ b/README.md
@@ -15,7 +15,20 @@ to pgbouncer host if IPv4 addressing has been used for the slony conninfos.
 
 The script can be either run on a schedule or as a daemon with the "D" flag:
 
-# pgbouncer_follower.pl -f <config file> [-D]
+```bash
+$ pgbouncer_follower.pl -f <config file> [-D]
+```
+
+To run as a daemon in debian:
+
+```bash
+$ sudo cp init.debian /etc/init.d/pgbouncer_follower_rw
+$ cp pgbouncer_follower.pl /var/slony/pgbouncer_follower/pgbouncer_follower.pl 
+$ cp pgbouncer_follower_rw.conf /var/slony/pgbouncer_follower/pgbouncer_follower_rw.conf 
+$ sudo chmod +x /etc/init.d/pgbouncer_follower_rw
+$ sudo update-rc.d pgbouncer_follower_rw start 99 2 3 4 5 . stop 24 0 1 6
+$ sudo invoke-rc.d pgbouncer_follower_rw start
+```
 
 ##Configuration options
 
@@ -30,12 +43,14 @@ The script can be either run on a schedule or as a daemon with the "D" flag:
 | pgBouncer | sets_to_follow         | text    | *1*                                         | Comma separated list of sets to follow or 'all' to follow all sets
 | pgBouncer | pool_mode              | 'ro/rw' | *'rw'*                                      | Select a read-only subscriber or the origin for read-write
 | pgBouncer | pool_all_databases     | boolean | *'false'*                                   | If true uses wildcard for database name in pgbouncer.ini, false uses slony database
+| pgBouncer | only_follow_origins    | boolean | *'false'*                                   | If true pgbouncer will only be reconfigured and reloaded when sets move origin
 | pgBouncer | status_file            | text    | *'/tmp/pgbouncer_follower_%mode.status'*    | File used to store a hash depicting the state of the cluster
 | pgBouncer | log_file               | text    | *'/tmp/pgbouncer_follower_%mode.log'*       | Log file for the script
 | pgBouncer | pid_file               | text    | *'/tmp/pgbouncer_follower_%mode.log'*       | PID file for the script when run as a daemon
 | pgBouncer | pool_conf_template     | text    | *'/etc/pgbouncer/pgbouncer_%mode.template'* | Template pgbouncer.ini file with your settings and a blank [databases] section
 | pgBouncer | pool_conf_target       | text    | *'/etc/pgbouncer/pgbouncer_%mode.ini'*      | Target pgbouncer.ini file to write a copy of pool_conf_template with a [databases] section to
 | pgBouncer | pool_reload_command    | text    | *'/etc/init.d/pgbouncer_%mode reload"'*     | System command to execute to reload pgbouncer instance
+| pgBouncer | max_ro_lag             | integer | *0*                                         | Maximum lag in seconds allowed for subscriber nodes when running in ro mode. 0 = don't monitor lag.
 
 The status_file, log_file, pid_file, pool_conf_template, pool_conf_target and 
 pool_reload_command parameters can contain the following special values: