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

Add gARP capability to L2 announcer feature #25933

Merged

Conversation

dylandreimerink
Copy link
Member

When failover occurs a different node will start responding to ARP.
But other nodes on the network will not know this has happened and thus
keep using the ARP entry from their local cache.

This PR makes it so we broadcast a gARP reply with the new MAC
address of the IP any time we reconcile a IP+ifidx tuple that was not
yet present in the L2 responder map.

Nodes that honor gARP replies will update their ARP cache to minimize
downtime. Those who do not honer these replies will have more downtime
until their ARP cache entry expires and they perform a ARP request
themselves.

Added gARP capability to L2 announcer feature

@dylandreimerink dylandreimerink added kind/enhancement This would improve or streamline existing functionality. release-note/misc This PR makes changes that have no direct user impact. labels Jun 6, 2023
@dylandreimerink dylandreimerink requested a review from a team as a code owner June 6, 2023 11:45
The garp package was sending out ARP requests, while valid in some
situations, what we actually need is to send out ARP replies which
tell nodes on the network what the new MAC address is for a given IP
instead of asking the nodes.

This commit also changes the `SendOnInterface` to `SendOnInterfaceIdx`
since the only call site for this function has indices not names
available.

Signed-off-by: Dylan Reimerink <dylan.reimerink@isovalent.com>
When failover occurs a different node will start responding to ARP.
But other nodes on the network will not know this has happened and thus
keep using the ARP entry from their local cache.

This commit makes it so we broadcast a gARP reply with the new MAC
address of the IP any time we reconcile a IP+ifidx tuple that was not
yet present in the L2 responder map.

Nodes that honor gARP replies will update their ARP cache to minimize
downtime. Those who do not honer these replies will have more downtime
until their ARP cache entry expires and they perform a ARP request
themselves.

Signed-off-by: Dylan Reimerink <dylan.reimerink@isovalent.com>
@dylandreimerink dylandreimerink requested a review from a team as a code owner June 6, 2023 12:07
Copy link
Member

@rolinh rolinh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

vendor changes lgtm

Copy link
Contributor

@ldelossa ldelossa left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

@dylandreimerink
Copy link
Member Author

dylandreimerink commented Jun 6, 2023

/test

Job 'Cilium-PR-K8s-1.26-kernel-net-next' failed:

Click to show.

Test Name

K8sDatapathConfig Iptables Skip conntrack for pod traffic

Failure Output

FAIL: Found 4 k8s-app=cilium logs matching list of errors that must be investigated:

Jenkins URL: https://jenkins.cilium.io/job/Cilium-PR-K8s-1.26-kernel-net-next/517/

If it is a flake and a GitHub issue doesn't already exist to track it, comment /mlh new-flake Cilium-PR-K8s-1.26-kernel-net-next so I can create one.

Then please upload the Jenkins artifacts to that issue.

Copy link
Contributor

@markpash markpash left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@dylandreimerink
Copy link
Member Author

/test-1.26-net-next

@maintainer-s-little-helper maintainer-s-little-helper bot added the ready-to-merge This PR has passed all tests and received consensus from code owners to merge. label Jun 7, 2023
@dylandreimerink dylandreimerink merged commit 376d005 into cilium:main Jun 7, 2023
62 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/enhancement This would improve or streamline existing functionality. ready-to-merge This PR has passed all tests and received consensus from code owners to merge. release-note/misc This PR makes changes that have no direct user impact.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants