-
Notifications
You must be signed in to change notification settings - Fork 448
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
stolonctl: implement postgres reload/restart #88
Comments
Closing since it's old and without any context. |
Hi @sgotti We need this feature of postgres restart to take effect of updated pgParameters like I went through this issue (#255) and got an idea of restarting the postgres instance of slave keepers first and then restarting the postgres instance of master. On restarting the postgres of master, sentinal will elect another healthy keeper as master We thought of implementing this feature as follows:
This would avoid downtime as well. But there are few gotchas
Any thoughts on this? |
@prabhu43 I reopened the issue (it was closed and I was losing your comment). Your proposal is basically an operator that handles a long running transaction. It requires a lot of logic to handle all the possible failures (it implements one of the possible workflows but there can be others). And as you said there're different gotchas that are difficult to know ahead of time since you should reimplement all the postgresql parameter checking logic. For this reason I won't add a command like Some notes
To be precise, restarting the master keeper doesn't imply that a new primary will be elected, if the restart is fast enough (usually) and doesn't fail due to wrong parameters the sentinel won't detect the master as failed and won't elect a new master. |
@prabhu43 and myself tried exactly this in this PR #561 We just blindy restart all 3 postgres and tested it out. It restarted very fast with very minimal downtime (lesser than 1 second) but it was triggered from a CLI command |
No description provided.
The text was updated successfully, but these errors were encountered: