Commit Graph

272 Commits

Author SHA1 Message Date
Jaime Casanova
499a501afd Make repmgr compatible with FreeBSD.
We need to add an #include and make it use a different path for the
"true" binary.

Maybe we need to make this changes for all BSD systems but having no
evidence of that i prefer to make this only for systems with __FreeBSD__
2012-09-15 17:37:59 -05:00
Jaime Casanova
0a9107d76d Improve sample of commands for promote and follow 2012-09-15 17:37:43 -05:00
Jaime Casanova
95ec0450da When we have more command-line arguments than we should have we
need to show that last value and we should use only optind for that
instead of optind+1
2012-08-30 02:11:48 -05:00
Jaime Casanova
57aa95f674 Fix documentation to always use -h sintax to refer to the node we
want to clone or connect to, instead of relying on the fact that
for some time putting that argument at last worked.
2012-08-30 02:10:10 -05:00
Jaime Casanova
56d2ae4e81 Fix HISTORY to show from newest to oldest v2.0beta1 2012-07-27 11:26:18 -05:00
Jaime Casanova
3edd87a041 Fix tabs in HISTORY 2012-07-27 11:20:56 -05:00
Jaime Casanova
740208da1c Fix typos in RELEASE NOTES 2012-07-27 11:15:50 -05:00
Jaime Casanova
664e1a8321 Now that we can have no monitoring we need to check all nodes at failover
not only those in repl_monitor
2012-07-21 17:49:38 -05:00
Jaime Casanova
d43c6334da Prepare HISTORY and release notes for release 2012-07-21 12:06:33 -05:00
Jaime Casanova
f984b3fd33 Document tunables added in aaf35947ed 2012-07-21 11:10:59 -05:00
Jaime Casanova
aaf35947ed Add tunables for connection retries to master and interval between
connection retries, these parameters along with master_response_timeout
determines the amount of time since failure to failover
2012-07-21 11:01:00 -05:00
Jaime Casanova
08ed0aa987 Commit 2d24518d9d added an additional
'}' at the end of parse_config(). removing.
2012-07-21 10:42:58 -05:00
Jaime Casanova
2d24518d9d If master_response_timeout hasn't been set in repmgr.conf it defaults
to zero, which was causing to a false positive in the failure detection
logic in wait_connection_availability(). So, change that to defaults to 60s
and add a check to avoid it being set to zero or negative.

Problem reported and analyzed by Andrew Newman
2012-07-21 09:49:05 -05:00
Jaime Casanova
a6c94b29de Change release notes because of commit bf241ba1d6 2012-07-06 02:00:46 -05:00
Jaime Casanova
bf241ba1d6 Make the monitoring history capabilities of repmgr be optional and
turned off by default. Most of it has been superseeded by
pg_stat_replication view, we can still start it by using the switch
--monitoring-history
2012-07-06 01:51:22 -05:00
Jaime Casanova
41dbc39527 Add release notes 2012-07-05 09:35:23 -05:00
Jaime Casanova
50b7147f15 Change Copyright date to cover 2012 2012-07-04 10:47:26 -05:00
Jaime Casanova
f5e57aa433 Add an option for "no-history" mode, where repmgrd just checks the
conectivity of master but don't INSERT any data into it
2012-07-04 10:07:31 -05:00
Jaime Casanova
ac5a9d1fd6 The release changed, just wait a little before setting it.
Also make well known names in HISTORY be only names, without
last name
2012-07-02 00:06:57 -05:00
Jaime Casanova
cb740b68be Add a check of the connection inside the CancelQuery() so it check
that before trying to cancel a query, which can block.
2012-06-26 11:29:02 -05:00
Jaime Casanova
d58ea77798 Add a quick setup for autofailover 2012-06-26 07:49:43 -05:00
Jaime Casanova
e3c3c22b6e Improve the version message to actually show the repmgr version not
only postgresql's one
2012-06-25 22:54:48 -05:00
Jaime Casanova
861a3c8f22 Fix CLUSTER CLEANUP, it needs to establish a local connection in order
to look for the master
2012-06-16 01:32:59 -05:00
Jaime Casanova
e51870b504 Force to enter a password for the superuser in the witness, this is
in case we need to send a password to connect as stated in
master's pg_hba.conf.
2012-06-15 13:51:45 -05:00
Jaime Casanova
5651720560 Remove a variable left in last commit 2012-06-15 09:46:01 -05:00
Jaime Casanova
d32a6cdb24 Remove kludge added to create user and db for witness.
It's too fragile, almost always cause a "segment violation" and
don't seems to be very useful.
2012-06-15 09:41:54 -05:00
Jaime Casanova
9e10987b90 Fix a few bugs introduced when merging features 2012-06-15 09:40:09 -05:00
Jaime Casanova
64fce88e99 Add a CLUSTER CLEANUP command to clean monitor's history,
also include a --keep-history (-k) option to indicate how many
days of history to keep
2012-06-13 00:39:54 -05:00
Jaime Casanova
7a76f1998c getMasterConnection() cannot avoid checking the same node that asks
to find the master.
This was a micro optimization based on the fact that all commands that
needed to detect the master were executed from the standby but now that
we have CLUSTER level commands that is not true anymore
2012-06-12 23:28:24 -05:00
Jaime Casanova
4db046a8ea Allow repmgr to obtain tablespace's locations from pg 9.2 and later
in which we no longer have a spclocation column in pg_tablespaces
2012-06-12 11:08:15 -05:00
Jaime Casanova
331eca447a STANDBY CLONE should be run by a SUPERUSER, otherwise we won't be able
to retrieve data_directory and the other parameters we need by
querying the database.
2012-06-12 09:42:50 -05:00
Jaime Casanova
b5b2f93f7e Merge branches 'master' and 'async' 2011-12-02 00:28:17 -05:00
Jaime Casanova
9d03d4a254 After checking that master is alive, is_pgup() should return not keep
checking forever.
2011-12-01 23:58:12 -05:00
Jaime Casanova
3b2ccc5b78 Add a master_response_timeout parameter and use it to limit the amount
of time we spent a reponse from master before declaring the failure.
Also, change is_pgup() so it use PQsendQuery() instead of PQexec to
execute the check of master
2011-12-01 01:20:33 -05:00
Jaime Casanova
89a1e2bcbd Not even consider old master as an option in failover 2011-11-27 19:17:59 -05:00
Jaime Casanova
7077a7c68f Add -w option to pg_ctl commands so we wait until command is finish.
Or at least, we try. By default, after 60 seconds pg_ctl just return.
This make useless to wait ourselves after pg_ctl start of witness so
remove the sleep
2011-11-27 18:38:53 -05:00
Jaime Casanova
9b8fb7e960 Remove last argument from log_err, left in commit 55c7ea4b5e.
Also rephrase the sentence

Reported by Jeroen Dekkers
2011-11-25 14:59:29 -05:00
Jaime Casanova
55c7ea4b5e Fix a wrong message.
It was saying the problem is the version of the PostgreSQL server while
it actually is because the MASTER REGISTER command was running on a
standby node
2011-11-10 09:38:12 -05:00
Jaime Casanova
0240cb2bfb Fix a typo introduced in commit cb764b180d 2011-11-03 12:50:51 -05:00
Jaime Casanova
2e64028f26 Add the improvement of the view repl_status to the history 2011-10-20 23:26:41 -05:00
Greg Smith
27396f462a Add strnlen on platforms that don't have it, such as OS X 2011-10-20 23:23:31 -05:00
Jaime Casanova
cb764b180d Let the clone happen in a session with synchronous_commit off. This
is because in pg 9.1 the default configuration can easily allow sync
rep to be activated even if no standby is present and will block
pg_start_backup() and pg_stop_backup() in that case.
2011-10-03 14:04:27 -05:00
Jaime Casanova
65cf045a63 Fix a few problems introduced in 020e17b059
while adding standby_name
2011-08-09 02:01:00 -05:00
Jaime Casanova
3d53661d97 Fix a typo introduced in the commit about standby_name
(020e17b059)
2011-08-09 01:14:50 -05:00
Jaime Casanova
7b3a9cbbe4 Rename standby_name configuration option as node_name
per gripe by Cedric
2011-08-09 01:01:37 -05:00
Jaime Casanova
276c947202 Add name to nodes and show it for the standby in repl_status. 2011-08-09 00:58:01 -05:00
Jaime Casanova
020e17b059 Add a new standby_name parameter that, when provided in repmgr.conf,
is included in the primary_conninfo as application_name... This is
a simple first step towards making repmgr works fine with 9.1 and
sync standbys
2011-08-09 00:57:23 -05:00
Jaime Casanova
10817ecffc Add "witness" as a node role in CLUSTER SHOW 2011-08-08 13:29:26 -05:00
Jaime2ndQuadrant
f26e37c087 Merge pull request #2 from 2ndquadrant-it/master
Add function to show nodes with actual roles: repmgr cluster show
2011-08-08 11:10:13 -07:00
Carlo Ascani
61c31eeb0c Added function to show nodes with actual roles: repmgr cluster show 2011-08-08 19:32:32 +02:00