-
Notifications
You must be signed in to change notification settings - Fork 33
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
Feature request: withdraw advertisements on shutdown #27
Comments
For your use-case the easiest and fastest way is to stop the bird daemon. It will yield what you want. Bird daemon is stopped during the shutdown process, so you don't need to do much with anycast-healthchecker. |
My NOC people get a little twitchy when BGP sessions are down, so I'd avoid taking them down for most of my use scenarios.
Yes, but that may cause service interruption as described above. Routes may not have converged into the routers' ASICs and traffic may still hit the machine while no service is up for responding. From my point of view, an additional parameter on the checks would do the trick. Probably
|
I never had a problem with this approach and if NOC is having issues when a BGP session is terminated then something is wrong, terminating a BGP session is a normal operational task and it shouldn't cause troubles, only an alert.
You can avoid this scenario with correct systemd ordering for Bird systemd service. I have had bird configured to start last on boot and stopped first on shutdown to avoid the scenario you describe.
Having I will try to cook something this weekend, let's see if I manage to find time for it. |
You are right, but the alert is something I'd like to avoid for most use cases.
I cobbled together a pull request but my python is far from any good. It's mostly copy/paste from your existing code with some stackoverflow sprinkled over it. It works but it's probably not very clean python. Feel free to adjust my code where there are more elegant ways. |
Is there a way to tell anycast-healthchecker to withdraw all announcements on a clean shutdown? Similar to
purge_ip_prefixes
but on exit?My scenario is, that I want to be able to perform some maintenance without interrupting any service to much.
Routers may take some time for announcements to converge. So if I shut down any healthchecked service it takes a few seconds before the healthchecker notices the service's unavailability and then again some time until the traffic no longer hits the system.
For a smooth transition my approach is to first withdraw all the routes on a system before shutting down any service.
Doing so by shutting down the anycast-healtchecker looks the cleanest to me. Everything else I can think of would be messing with the healthchecker and probably result in attempts by it to fix the configuration.
The text was updated successfully, but these errors were encountered: