-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
zebra: fix route deletion during zebra shutdown #15424
Conversation
This patch fixes issues Bug reproduction (on staticd example) with current master build (9.2):
i.e. the tail of the queued deletion events remained unprocessed. Please review. |
@Mergifyio backport dev/10.0 stable/9.1 |
🟠 Waiting for conditions to match
|
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.
New ASAN failure, see here https://ci1.netdef.org/browse/FRR-PULLREQ3-2001/artifact/ASANP3/AddressSanitizerError/AddressSanitzer.txt. Need to fix this.
So the commit you refer to believed it was fixing an ordering problem with vrfs - is that problem still fixed, or will it reappear if this change is merged? |
vrf_terminate() is a library function, it calls disable() (if not already disabled) and delete() (releases resources). |
✅ Backports have been created
|
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.
looks good
Added code cleanup requested by @mjstapp. |
f5626ec
to
31065d5
Compare
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.
This version looks good - but I see that there are two commits here, when really there should just be the one that makes this set of changes. Can you remove or squash the other commit?
Split zebra's vrf_terminate() into disable() and delete() stages. The former enqueues all events for the dplane thread. Memory freeing is performed in the second stage. Signed-off-by: Alexander Skorichenko <[email protected]>
Pushed in a single commit. |
so the tests need to pass - but if you look at the results summary, you'll see that there's a button that reruns just the failed tests, which is very useful. I've asked for that rerun - let's see if it's clean. |
zebra: fix route deletion during zebra shutdown (backport #15424)
zebra: fix route deletion during zebra shutdown (backport #15424)
Restore the order of execution in zebra's main thread:
vrf_terminate();
zebra_dplane_finish();
zebra_dplane_shutdown();
changed in commit 3b0e170.
vrf_terminate() enqueues routes for deletion in dplane thread.
zebra_dplane_shutdown() effectively forces dplane thread
to immediately cease and join (leaving unprocessed routes), while
zebra_dplane_finish() has a condition that prevents
zebra_dplane_shutdown() from running until all routes queued for dplane thread have been deleted.
Closes #14062
Closes #14178