Ian Barwick
5a7ce552f0
"renumber" deprecated command line options without a short version
...
This will keep them out of the main list.
2016-08-17 14:51:32 +09:00
Ian Barwick
ef7bed1b3d
repmgrd: refactor standby monitoring status query and code
...
This had grown somewhat complex with addition of handling for
various corner cases. Much of the work has now been delegated
to the query itself.
2016-08-16 19:15:58 +09:00
Ian Barwick
6bd1c6a36d
Skip largely pointless master reconnection attempt.
...
Experimental - see notes in code.
2016-08-16 13:25:39 +09:00
Ian Barwick
9831cabd4d
Minor refactoring of do_master_failover()
...
- rename some variables for clarity
- ensure all structures are initialised correctly
- update code comments
2016-08-16 11:23:59 +09:00
Ian Barwick
d244fb29d7
Update HISTORY
2016-08-15 13:15:55 +09:00
Ian Barwick
4a349f7224
repmgr: emit warning if a deprecated command line option is used
2016-08-15 12:27:55 +09:00
Ian Barwick
fb6109b3e6
Update README.md
...
Note default usage of `pg_basebackup --xlog-method=stream`.
2016-08-15 10:16:22 +09:00
Martín Marqués
b314f5aaf4
Merge pull request #225 from ryno83/patch-1
...
Update README.md
2016-08-12 19:52:25 +02:00
Renaud Fortier
7fc340a8e2
Update README.md
...
I think this will improve the readme.
2016-08-12 10:28:31 -04:00
Ian Barwick
e4c8bd981b
Update HISTORY
2016-08-12 09:59:10 +09:00
Ian Barwick
a310417a49
Refactor standby monitoring query
...
Addresses GitHub #224
2016-08-11 17:28:16 +09:00
Ian Barwick
9a07686ceb
When the output of a remote command isn't required, ensure it's consumed anyway
...
This fixes a regression introduced with commit 85f68e9f77
Also clean up some code made redundant by same.
2016-08-11 08:46:55 +09:00
Ian Barwick
45aa0724c4
Update HISTORY
...
Also remove code comment obsoleted by previous commit
2016-08-09 15:32:56 +09:00
Ian Barwick
a558e9379e
Merge branch 'gciolli-fix_219'
...
PR #220 resolving GitHub #219
2016-08-09 15:29:59 +09:00
Gianni Ciolli
85f68e9f77
Only collect remote command output if the caller requires it
...
This addresses GitHub #216 and #167 .
2016-08-09 14:14:52 +09:00
Ian Barwick
00e55c0672
Update HISTORY
2016-08-09 12:29:19 +09:00
Ian Barwick
84ab37c600
Improve handling of failover events when failover is set to manual
...
- prevent repmgrd from repeatedly executing the failover code
- add event notification 'standby_disconnect_manual'
- update documentation
This addresses GitHub #221 .
2016-08-09 12:09:09 +09:00
Ian Barwick
6a198401db
Fix repmgrd's command line help option parsing
...
As in commit d0c05e6f46 , properly distinguish between
the command line option -? and getopt's unknown option marker '?'
2016-08-08 21:17:56 +09:00
Ian Barwick
cb78802027
repmgrd: prevent endless loops in failover with manual node
...
The LSN reported by the shared memory function defaults to "0/0"
(InvalidXLogRecPtr) - this indicates that the repmgrd on that node
hasn't been able to update it yet. However during failover several
places in the code assumed this is an error, which would cause
an endless loop waiting for updates which would never come.
To get around this without changing function definitions, we can
store an explicit message in the shared memory location field so the
caller can tell whether the other node hasn't yet updated the field,
or encountered situation which means it should not be considered
as a promotion candidate (which in most cases will be because
`failover` is set to `manual`.
Resolves GitHub #222 .
2016-08-08 14:29:24 +09:00
Gianni Ciolli
48f637486d
Now STANDBY SWITCHOVER and STANDBY FOLLOW log an event notification on
...
success and also on some failures, precisely those when it makes sense
or it is reasonably possible to do so.
2016-08-05 14:19:04 +02:00
Ian Barwick
73280a426b
Update HISTORY
2016-08-05 16:43:52 +09:00
Ian Barwick
b8ee321d5f
Merge branch 'gciolli-feature-better-auto-deb'
...
GitHub pull request #218
2016-08-05 16:42:27 +09:00
Gianni Ciolli
ccdc0f9871
Improved "repmgr-auto" Debian package
...
* Version set to 3.2dev
* Binaries are placed in PGBINDIR and then linked from /usr/bin,
instead of being placed into /usr/bin directly. This is necessary
for the switchover command, because it requires pg_rewind, which is
placed in PGBINDIR too.
2016-08-05 09:34:32 +02:00
Ian Barwick
89aeccedc2
Various bugfixes and code documentation improvements
2016-08-04 12:31:24 +09:00
Ian Barwick
d9bda915bb
Update documentation and --help output for witness register
...
This completes the implementation of GitHub #186
2016-08-04 10:36:26 +09:00
Ian Barwick
c565be4ab6
Improve database connection status checking
2016-08-04 10:36:21 +09:00
Ian Barwick
c26fd21351
Implement repmgr standby register command
2016-08-04 10:36:16 +09:00
Ian Barwick
6b57d0e680
Separate witness registration into do_witness_register()
2016-08-04 10:36:12 +09:00
Ian Barwick
6faf029c93
Add witness unregister command info in help output
2016-08-02 18:39:04 +09:00
Ian Barwick
c42437a4f2
standby/witness unregister - enable even if node isn't running
...
If the `--node` option is provided with the id of the node to unregister,
the action can be executed on any node.
This addresses GitHub #211 .
2016-08-02 17:09:27 +09:00
Ian Barwick
d0c05e6f46
Clean up command line option handling and help output
...
- properly distinguish between the command line option -? and getopt's
unknown option marker '?'
- remove deprecated command line options --initdb-no-pwprompt and
-l/--local-port
- add witness command summary in help output
2016-08-02 14:40:13 +09:00
Ian Barwick
050f007cc2
Initial implementation of witness unregister
2016-08-02 12:22:54 +09:00
Ian Barwick
371d80ff35
Document repmgr cluster show --csv
2016-08-01 16:10:10 +09:00
Ian Barwick
e0a61afb7d
Suppress connection error display in repmgr cluster show
...
This prevents connection error messages being mixed in
with `repmgr cluster show` output. Error message output can
still be enabled with the --verbose flag.
Fixes GitHub #215
2016-08-01 14:57:40 +09:00
Ian Barwick
bbc88ce05c
Miscellaneous code cleanup and typo fixes
2016-07-28 16:32:07 +09:00
Ian Barwick
61e907cf70
Update README
...
Default log level is NOTICE, not INFO.
2016-07-27 12:11:00 +09:00
Ian Barwick
02668ee045
Parse the contents of the "pg_basebackup_options" parameter in repmgr.conf
...
This is to ensure that when repmgr executes pg_basebackup it doesn't
add any options which would conflict with user-supplied options.
This is related to GitHub #206 , where the -S/--slot option has been
added for 9.6 - it's important to check this doesn't conflict with
-X/--xlog-method.
While we're at it, rename the ErrorList handling code to ItemList
etc. so we can use it for generic non-error-related lists.
2016-07-26 16:12:43 +09:00
Ian Barwick
36eb26f86d
Mark some variables as static.
2016-07-26 11:40:26 +09:00
Ian Barwick
cbc2c7b3e6
From PostgreSQL 9.6, use pg_basebackup's -S/--slot option if appropriate
...
GitHub #206
2016-07-26 10:35:30 +09:00
Ian Barwick
8a28dadde4
Rename RECOVERY_FILE to RECOVERY_COMMAND_FILE
...
This is for consistency with the PostgreSQL source code (see:
src/backend/access/transam/xlog.c ), but as it's not exported
we need to define it ourselves anyway.
2016-07-26 09:19:52 +09:00
Ian Barwick
3eda7373ad
Prevent duplicated parameters being passed to pg_basebackup
...
This was not a problem, but ugly.
2016-07-25 20:44:36 +09:00
Ian Barwick
34e574ac66
Update README
...
Add caveats for pg_rewind with 9.4 and 9.3 in particular, also fix typo.
2016-07-21 08:58:44 +09:00
Ian Barwick
e8fcc3d7a6
repmgr: set default user for -R/--remote-user
2016-07-18 14:30:30 +09:00
Ian Barwick
eba0f1d7ae
Update README with note about using screen et al
2016-07-18 11:01:42 +09:00
Ian Barwick
db32565b36
Add notes about setting pg_bindir for Debian/Ubuntu-based distributions.
...
repmgr doesn't know about pg_ctlcluster.
Per GitHub query #196 .
2016-07-15 16:00:31 +09:00
Ian Barwick
94befc3230
repmgr standby clone historically accepts a hostname as third parameter
2016-07-15 11:17:05 +09:00
Ian Barwick
340899f082
Update README
...
Add note about 2ndQuadrant RPM repository.
2016-07-13 09:55:01 +09:00
Ian Barwick
76681c0850
Update code comments
2016-07-12 10:56:31 +09:00
Ian Barwick
eebaef59a3
Remove unused error code ERR_BAD_PASSWORD
2016-07-12 09:36:50 +09:00
Ian Barwick
ddaaa28449
README: update error code list
2016-07-12 09:35:52 +09:00