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

Automated cherry pick of #4428: Bugfix: Pod or gateway interface use a different MAC from the #4451

Conversation

wenyingd
Copy link
Contributor

@wenyingd wenyingd commented Dec 7, 2022

Cherry pick of #4428 on release-1.7.

#4428: Bugfix: Pod or gateway interface use a different MAC from the

For details on the cherry pick process, see the cherry pick requests page.

@wenyingd wenyingd added the kind/cherry-pick Categorizes issue or PR as related to the cherry-pick of a bug fix from the main branch to a release label Dec 7, 2022
@codecov
Copy link

codecov bot commented Dec 7, 2022

Codecov Report

Merging #4451 (da7535d) into release-1.7 (693f568) will decrease coverage by 0.60%.
The diff coverage is 52.72%.

Impacted file tree graph

@@               Coverage Diff               @@
##           release-1.7    #4451      +/-   ##
===============================================
- Coverage        64.06%   63.46%   -0.61%     
===============================================
  Files              293      293              
  Lines            43417    43460      +43     
===============================================
- Hits             27815    27580     -235     
- Misses           13362    13690     +328     
+ Partials          2240     2190      -50     
Flag Coverage Δ
e2e-tests 44.54% <49.09%> (?)
kind-e2e-tests 48.95% <49.09%> (-1.49%) ⬇️
unit-tests 44.83% <41.50%> (+0.15%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
pkg/ovs/ovsconfig/ovs_client.go 51.52% <40.00%> (+4.75%) ⬆️
pkg/agent/agent.go 58.55% <58.33%> (+5.09%) ⬆️
pkg/agent/util/net.go 31.90% <62.50%> (-16.29%) ⬇️
...g/agent/cniserver/interface_configuration_linux.go 17.15% <100.00%> (+0.20%) ⬆️
pkg/agent/interfacestore/types.go 77.77% <100.00%> (+8.33%) ⬆️
pkg/controller/egress/store/egressgroup.go 1.72% <0.00%> (-54.32%) ⬇️
pkg/agent/route/route_linux.go 30.98% <0.00%> (-17.70%) ⬇️
pkg/agent/controller/networkpolicy/packetin.go 57.74% <0.00%> (-11.98%) ⬇️
pkg/agent/util/ipset/ipset.go 59.45% <0.00%> (-10.82%) ⬇️
... and 26 more

@wenyingd wenyingd force-pushed the automated-cherry-pick-of-#4428-upstream-release-1.7 branch from ed04b7c to bd84b70 Compare December 7, 2022 06:39
…tion

This issue is found on Ubuntu 22.04: the network interface for antrea-gw0
is different from the one we used in OpenFlow rules.

The reason is systemd-udev has modified the interface's MAC after it watches
a new one is created. So if Antrea Agent reads interface's information before
systemd-udev's modification, Antrea Agent would uses an incorrect value to
install OpenFlow rules.

To resolve the issue,
  1. Agent generates a static MAC for antrea-gw0 or the interface used by Pod
  2. Agent uses the generated MAC to create OVS internal port or veth pair

To implement the logic, some code is copied from containernetworking/plugins/ip/link_linux
latest versions to path thirdparty, this is to avoid unexpected issues introduced
when bumping up the dependent libraries.

Signed-off-by: wenyingd <wenyingd@vmware.com>
@wenyingd wenyingd force-pushed the automated-cherry-pick-of-#4428-upstream-release-1.7 branch from bd84b70 to da7535d Compare December 7, 2022 06:41
@wenyingd wenyingd requested a review from tnqn December 13, 2022 10:48
@wenyingd
Copy link
Contributor Author

/test-all

@tnqn
Copy link
Member

tnqn commented Dec 13, 2022

/skip-e2e which failed on testOVSFlowReplay but the reason was unrelated to the PR, #4475 will fix it.

@tnqn tnqn merged commit 285cc46 into antrea-io:release-1.7 Dec 13, 2022
@wenyingd wenyingd deleted the automated-cherry-pick-of-#4428-upstream-release-1.7 branch May 30, 2023 06:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/cherry-pick Categorizes issue or PR as related to the cherry-pick of a bug fix from the main branch to a release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants