Ian Barwick
52905f1eb3
Standardize on "ID: %i" when logging node IDs
...
Previously there was a mix of "id:", "node id:", "node ID:" and "node_id:".
2019-04-30 17:07:33 +09:00
Ian Barwick
6c3b4c0db8
Remove unused line
2019-04-30 15:53:24 +09:00
Ian Barwick
89a7261483
Always quote node names in log messages
2019-04-30 15:52:56 +09:00
Frantisek Holop
d7de0a64e0
doc: bit too many e.g.'s
...
PR #565 .
2019-04-30 10:47:45 +09:00
Frantisek Holop
531c4d9853
doc: promote -> follow
...
PR #565
2019-04-30 10:43:15 +09:00
Ian Barwick
356fe2e640
Fix "repmgr daemon status --csv" output
2019-04-29 20:52:27 +09:00
Ian Barwick
e32acda8c0
standby switchover: ignore nodes which are unreachable and marked as inactive
...
Previously "repmgr standby switchover" would abort if any node was unreachable,
as that means it was unable to check if repmgrd is running.
However if the node has been marked as inactive in the repmgr metadata, it's
reasonable to assume the node is no longer part of the replication cluster
and does not need to be checked.
2019-04-29 14:35:49 +09:00
Ian Barwick
5f10e68f31
emit warning if "--siblings-follow" provided out-of-context
2019-04-29 14:12:22 +09:00
Ian Barwick
87910a5448
repmgrd: improve logging of sibling node's upstream info
...
If the sibling node has already been promoted (for whatever
reason, e.g. "repmgr standby promote" was executed manually)
and has exited recovery, the upstream node ID will normally
be reported as "-1", which is correct, but looks confusing in
the logs.
We now only report the upstream node ID if the sibling node
is still in recovery, *or* if it has exited recovery but is
still reporting an extant node ID.
2019-04-29 13:51:17 +09:00
Ian Barwick
ec6266e375
doc: list caveats when monitoring child node disconnection
2019-04-25 17:52:14 +09:00
Ian Barwick
2082a8d3f3
Consolidate some code
2019-04-25 16:04:40 +09:00
Ian Barwick
c8d52bab6d
cluster show: fix thinko introduced in commit 9fe2fa2
2019-04-25 15:46:07 +09:00
Ian Barwick
dbbf35ded1
Update HISTORY
2019-04-25 14:59:33 +09:00
Ian Barwick
9fe2fa2daf
daemon status: make output more like that of "cluster show"
...
In particular make any issues with unexpected server state more
obvious.
2019-04-25 14:45:41 +09:00
Ian Barwick
da24896fd5
doc: add child node monitoring example
2019-04-24 16:04:47 +09:00
Ian Barwick
c092ce60a7
doc: document "child_node..." configuration parameters
2019-04-24 14:48:38 +09:00
Ian Barwick
090493ebc9
doc: document "child_node" events
2019-04-24 13:19:00 +09:00
Ian Barwick
8d80267ab1
doc: update "repmgr primary register" output
2019-04-24 13:18:31 +09:00
Ian Barwick
3231b5034d
Remove temporary debugging log output
2019-04-24 13:17:52 +09:00
Ian Barwick
5a9175c740
Clarify hints about updating the repmgr extension
2019-04-24 11:37:31 +09:00
Ian Barwick
58b33fb411
Clarify a couple of code comments
2019-04-24 10:55:53 +09:00
Ian Barwick
3129da221e
"primary register": ensure --force works if another primary is registered but not running
2019-04-23 16:54:07 +09:00
Ian Barwick
6cbf436bf8
Don't execute "child_nodes_disconnect_command" when repmgrd paused
2019-04-23 14:08:13 +09:00
Ian Barwick
5a90513878
repmgrd: monitor standbys attached to primary
...
This functionality enables repmgrd (when running on the primary) to
monitor connected child nodes. It will log connections and disconnections
and generate events.
Additionally, repmgrd can execute a custom script if the number of connected
child nodes falls below a configurable threshold. This script can be used
e.g. to "fence" the primary following a failover situation where a new primary
has been promoted and all standbys are now child nodes of that primary.
2019-04-22 16:18:52 +09:00
Ian Barwick
64c4cb81d5
Update pg_control processing for PostgreSQL 12
2019-04-18 09:31:33 +09:00
Ian Barwick
3115face28
doc: add note about when a PostgreSQL restart is required
...
Per query in GitHub #564 .
2019-04-17 09:43:35 +09:00
Ian Barwick
80f66e87c9
Improve string handling during configuration file reload
2019-04-16 11:20:41 +09:00
Ian Barwick
ad28cf95bd
standby register: add upstream node ID in event details
2019-04-16 11:01:22 +09:00
Ian Barwick
a0c6cb602f
repmgrd: remove duplicate function definition
2019-04-16 10:53:05 +09:00
Ian Barwick
27803f93ff
repmgrd: always unset upstream node ID when monitoring a primary
2019-04-12 12:26:39 +09:00
Ian Barwick
1a344d488a
Use sizeof() consistently
2019-04-11 23:07:58 +09:00
Ian Barwick
46d17d0933
repmgrd: fix log output
2019-04-11 16:29:08 +09:00
Ian Barwick
6b79e08706
repmgrd: add addiitonal log output in do_election()
2019-04-11 15:46:20 +09:00
Ian Barwick
cd6a55c7cb
repmgrd: improve primary visibility consensus check
...
Exclude sibling nodes which report they're following a different
node. This shouldn't happen, but could.
2019-04-11 15:46:14 +09:00
Ian Barwick
008bd00a59
repmgrd: store upstream node ID in shared memory
2019-04-11 15:46:09 +09:00
Ian Barwick
5a8741199f
repmgrd: exclude witness server from followability check
2019-04-11 11:19:12 +09:00
Ian Barwick
dd454a8374
Miscellaneous string handling cleanup
...
This is mainly to prevent effectively spurious truncation warnings
in recent GCC versions.
2019-04-10 16:18:56 +09:00
Ian Barwick
a9b56d9833
Fix hint message
...
s/UPGRADE/UPDATE
2019-04-10 12:08:26 +09:00
Ian Barwick
ef47589c6b
standby clone: always ensure directory is created with correct permissions
...
In Barman mode, if there is an existing, populated data directory, and
the "--force" option is provided, the entire directory was being deleted,
and later recreated as part of the rsync process, but with the default
permissions.
Fix this by recreating the data directory with the correct permissions
after deleting it.
2019-04-09 10:58:27 +09:00
Ian Barwick
77b9887d61
standby clone: improve --dry-run behaviour in barman mode
...
- emit additional informational output
- ensure that provision of --force does not result in an existing
data directory being modified in any way
2019-04-08 15:12:22 +09:00
Ian Barwick
7631c60933
doc: update release notes
2019-04-08 11:27:25 +09:00
Ian Barwick
a8d560860d
Ensure BDR-specific code only runs on BDR 2.x
...
The BDR support in repmgr is for a specific BDR 2.x use case, and
is not suitable for more recent BDR versions.
2019-04-05 14:37:49 +09:00
Ian Barwick
c338bc9c5e
doc: add note about BDR replication type in sample config
2019-04-05 14:37:49 +09:00
Ian Barwick
3c8e42ff15
doc: emphasise that BDR2 support is for BDR2 only
2019-04-05 10:53:23 +09:00
Ian Barwick
be9c6d5fc6
Use correct sizeof() argument in a couple of strncpy calls
...
Source and destination buffers are however the same length in both cases.
Per GitHub #561 .
2019-04-04 10:58:00 +09:00
Ian Barwick
55e79bd0b7
doc: update 4.3 release notes
2019-04-03 15:08:35 +09:00
Ian Barwick
8970a72be9
doc: update README
...
Link to current documentation version
2019-04-03 11:12:48 +09:00
Ian Barwick
7791abb8f7
doc: add a link to the current documentation from the contents page
2019-04-03 10:54:18 +09:00
Ian Barwick
602e06a8f4
doc: finalize 4.3 release notes
2019-04-02 14:42:06 +09:00
Ian Barwick
84f4c6c979
doc: note that --siblings-follow will become default in a future release
2019-04-02 11:04:36 +09:00