Skip to content
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

Snapshot Segment Mismatch #235

Open
fredfortier opened this issue Mar 4, 2022 · 2 comments
Open

Snapshot Segment Mismatch #235

fredfortier opened this issue Mar 4, 2022 · 2 comments

Comments

@fredfortier
Copy link

I'm aware that this is likely an implementation issue on my part, but do you have any hint on what could explain an error like this when installing a snapshot.

Failed to install snapshot "snapshot segment id mismatch, expect: snapshot-257+0, got: snapshot-257+39845888"

I haven't reproduced this consistently yet, but I'm working on it. I've this error with earlier versions of async_raft. I know it happens with large snapshots but I don't know yet whether there's a threshold. Any pointers would be appreciated.

@github-actions
Copy link

github-actions bot commented Mar 4, 2022

👋 Thanks for opening this issue!

Get help or engage by:

  • /help : to print help messages.
  • /assignme : to assign this issue to you.

@drmingdrmer
Copy link
Member

It looks like there is a retransmit of a snapshot segment.

The follower/learner has finished installing a snapshot and has cleaned up the session by setting RaftCore.snapshot_state to None.

But the leader did not wait long enough for the follower/learner to respond.
Then the leader retransmitted a segment.

To confirm that, you need to check the debug level log to see if there are a retransmitted snapshot segment.
The debug logging statement is:

            // Send the RPC over to the target.
            tracing::debug!(
                snapshot_size = req.data.len(),
                req.offset,
                end,
                req.done,
                "sending snapshot chunk"
            );

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants