-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
VAULT-14048: raft-autopilot appears to refuse to remove a node which has left and wouldn't impact stability #19472
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
peteski22
added
bug
Used to indicate a potential bug
core
Issues and Pull-Requests specific to Vault Core
labels
Mar 7, 2023
ncabatoff
reviewed
Mar 14, 2023
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is the absence of a new test because we don't think it's necessary, or because we're not sure how to write one?
peteski22
assigned hc-github-team-secure-vault-core and unassigned hc-github-team-secure-vault-core
Mar 24, 2023
miagilepner
reviewed
Mar 27, 2023
miagilepner
reviewed
Mar 27, 2023
Co-authored-by: Nick Cabatoff <ncabatoff@hashicorp.com>
raskchanky
reviewed
Mar 27, 2023
ncabatoff
reviewed
Apr 3, 2023
ncabatoff
approved these changes
Apr 3, 2023
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This bug was detected during manual testing for the
1.13.0
release and as a precaution the following PRs were reverted:After some investigation the problem seems to be that the
NodeType
isn't being supplied by Vault when autopilot asks it for itsKnownServers
during pruning. As a result there are no potential voters flagged in the voter registry, we have amaxRemoval
which is< 1
which triggers the debug message about removing a majority of voting servers being unsafe and autopilot refuses to remove the failed voting server.This PR adds the
NodeType
for the leader and, where possible, for the follower nodes. It also restores the autopilot version tov0.2.0
.Files of note:
go.mod
physical/raft/raft_autopilot.go
vault/external_tests/raft/raft_autopilot_test.go
Most other changed files are due to exportingGetRaftBackend
.Tests added:
(Ent)TestDelegate_KnownServers_NodeType
TestRaft_Autopilot_DeadServerCleanup
Following a successfully merged PR I will raise an Enterprise specific PR to update the packages and add another test.