-
Notifications
You must be signed in to change notification settings - Fork 458
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
ovn lb select the local chassis's backend prefer #4894
base: master
Are you sure you want to change the base?
Conversation
Pull Request Test Coverage Report for Build 13255351680Warning: This coverage report may be inaccurate.This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.
Details
💛 - Coveralls |
93b8ed4
to
318cff3
Compare
318cff3
to
cdbf329
Compare
cdbf329
to
ffd7994
Compare
ffd7994
to
21e47a8
Compare
21e47a8
to
2ade8ff
Compare
2ade8ff
to
add2969
Compare
8a81fc8
to
4bd7410
Compare
a703a56
to
d1385c6
Compare
48a02a6
to
692ec96
Compare
692ec96
to
c24b4c3
Compare
The following occasional failure need to be fixed: [FAILED] Code Location: /home/zhang/kube-ovn/test/e2e/metallb/e2e_test.go:417
Expected
<string>: kube-ovn-control-plane
to equal
<string>: kube-ovn-worker
In [It] at: /home/zhang/kube-ovn/test/e2e/metallb/e2e_test.go:358 @ 02/06/25 02:45:06.75 |
I tested in my local env and github CI flow, but not find this error |
matallb 也可以使用 kube-ovn unerlay subnet 中 exclude 中的 ip:metallb 使用 br-provider 网桥么, 这样 metallb 可以将流量转到 kube-ovn underlay subnet pod 内, 这样子使用吗? |
是的 |
Signed-off-by: clyi <[email protected]>
Signed-off-by: clyi <[email protected]>
Signed-off-by: clyi <[email protected]>
Signed-off-by: clyi <[email protected]>
Signed-off-by: clyi <[email protected]>
5984750
to
d091293
Compare
Signed-off-by: clyi <[email protected]>
0ce2f62
to
4250649
Compare
Signed-off-by: clyi <[email protected]>
not check l2servicestatus Signed-off-by: clyi <[email protected]>
2e7a692
to
eb38483
Compare
It should be a problem with the l2servicestatus field of metallb. It seems that the status.node of this field is not necessarily the node where the vip is located. It is probably a metallb bug. |
If the |
Pull Request
What type of this PR
Examples of user facing changes:
ovn 实现原理。
OVN 这部分代码修改原理:
实现原理是获取到vip backend的 chassis , 新增加流表入下:
is_chassis_resident("nginx-6f55f97f94-8kvlx.default") , 其中 nginx-6f55f97f94-8kvlx.default 是某个vip 的backend下的任意一个lsp,backends=10.16.0.3:80 表示这个lb 在这个chassis下的所有backendip: port 。
如果hit不到以上流表,就会走原来的ovn lb 规则。
该功能需要配置Load_balancer的 两个字段
option:prefer_local_backend
ip_port_mappings
kube-ovn 增加场景
场景1:switchlbRules 支持 OVN LB 优先走本地 backend
使用方法:
kube-ovn-controller 开启开关 --enable-ovn-lb-prefer-local = true
用例:
场景2: ovn lb 模式下支持 internalTrafficPolicy: Local , 真正实现发送本地 backend
使用方法:
kube-ovn-controller 开启开关 --enable-ovn-lb-prefer-local = true
用例:
场景3:underlay 模式下 和 metallb 一起使用, 该场景主要是为了metallb 模式下支持某个underlay subnet提供外部地址池的vip, vip的后端pod同样在该子网下, 并保证clientIP 不被改变。
流量走向:
使用方法:
Which issue(s) this PR fixes
Fixes #(issue-number)