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

v1.13 Backports 2023-04-05 #24758

Merged
merged 8 commits into from
Apr 6, 2023
Merged

v1.13 Backports 2023-04-05 #24758

merged 8 commits into from
Apr 6, 2023

Conversation

jibi
Copy link
Member

@jibi jibi commented Apr 5, 2023

Once this PR is merged, you can update the PR labels via:

for pr in 24624 24715 24570 24711 24723 24681; do contrib/backporting/set-labels.py $pr done 1.13; done

or with

make add-labels BRANCH=v1.13 ISSUES=24624,24715,24570,24711,24723,24681

sayboras and others added 5 commits April 5, 2023 09:29
[ upstream commit 9629343 ]

This commit is to make sure that if there is any changes in namespace
mentioned in gateway.spec.listener[*].allowRoutes, the reconciliation
loop should kick off for Gateway resource. For example, the namespace
label can be added to be included or excluded from what mentioned in
gateway.spec.listener[*].allowRoutes.

Signed-off-by: Tam Mach <tam.mach@cilium.io>
Signed-off-by: Gilberto Bertin <jibi@cilium.io>
[ upstream commit 4aa6911 ]

If we can read "procfs" the user will not the reason for it. We should
log the error as well.

Signed-off-by: André Martins <andre@cilium.io>
Signed-off-by: Gilberto Bertin <jibi@cilium.io>
[ upstream commit 60bb0ea ]

BPFSocketLBHostnsOnly is outputted in the Kube Proxy Replacement section in cilium status --verbose:

$ cilium status --verbose
[...]
KubeProxyReplacement Details:
  [...]
  Socket LB Coverage:     Hostns-only
  [...]

Fixes: #24160

Signed-off-by: Roman Ptitcyn <romanspb@yahoo.com>
Signed-off-by: Gilberto Bertin <jibi@cilium.io>
[ upstream commit 2f9850c ]

The upgradeCompatability should always be set to the first version that
the user installed in order to assume the Helm defaults that were in
place during that release.

Tracking each version here initially would provide confirmation for
users in order to pick a valid version. Except that we forgot to keep it
up to date with each release.

Drop the examples to reduce user confusion.

Signed-off-by: Joe Stringer <joe@cilium.io>
Signed-off-by: Gilberto Bertin <jibi@cilium.io>
[ upstream commit e773f7e ]

Following up on #23334, add more exceptions for errors that seem to not
be related to Cilium but rather to etcd.

Fixes: #24701
Suggested-by: André Martins <andre@cilium.io>
Signed-off-by: Gilberto Bertin <jibi@cilium.io>
Signed-off-by: Gilberto Bertin <jibi@cilium.io>
@jibi jibi requested review from a team as code owners April 5, 2023 09:30
@jibi jibi added the kind/backports This PR provides functionality previously merged into master. label Apr 5, 2023
@jibi jibi requested a review from nathanjsweet April 5, 2023 09:30
@jibi jibi added the backport/1.13 This PR represents a backport for Cilium 1.13.x of a PR that was merged to main. label Apr 5, 2023
Copy link
Member

@sayboras sayboras left a comment

Choose a reason for hiding this comment

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

Thanks and looks good for my changes

[ upstream commit 89a1936 ]

The restore code attempts to reconcile datapath state with
the userspace state post agent restart. Bailing out early
on failures prevents any remediation from happening, so
log any errors. Follow-up commits will try to handle leaked
backends in the cluster if any.

Signed-off-by: Aditi Ghag <aditi@cilium.io>
Signed-off-by: Gilberto Bertin <jibi@cilium.io>
[ upstream commit ebe2b55 ]

The restore logic attempts to reconcile datapath state
with the userspace post agent restart.
Previously, it first restored backends from the `lb4_backends`
map before restoring service entries from the `lb4_services`
map. If there were error scenarios prior to agent restart (for
example, backend map full because of leaked backends), the logic
would fail to restore backends currently referenced in the services
map (and as a result, selected for load-balancing traffic).

This commit prioritizes restoring service entries followed by
backend entries. Follow-up commit handles error cases such as leaked
backends by keeping track of backends retrieved from restoration of
service entries, and then using that to subsequently restore backends.

Signed-off-by: Aditi Ghag <aditi@cilium.io>
Signed-off-by: Gilberto Bertin <jibi@cilium.io>
[ upstream commit 5311f81 ]

In certain error scenarios, backends can be leaked, where
they were deleted from the userspace state, but left in the
datapath backends map. To reconcile datapath and userspace,
identify such backends that were created with different IDs
but same L3n4Addr hash.
This commit builds up on previous commits that don't bail out
on such error conditions (e.g., backend IDs mismatch during restore),
and tracks backends that are currently referenced in service entries
restored from the lb4_services map to restore backend entries.
Furthermore, it uses the tracked state to delete any duplicate backends
that were previously leaked.

Fixes: b79a4a5 (pkg/service: Gracefully terminate service backends)

Signed-off-by: Aditi Ghag <aditi@cilium.io>
Signed-off-by: Gilberto Bertin <jibi@cilium.io>
@aditighag
Copy link
Member

#24681

Looks good for my changes. Thanks a lot!

@jibi
Copy link
Member Author

jibi commented Apr 5, 2023

/test-backport-1.13

Job 'Cilium-PR-K8s-1.24-kernel-5.4' failed:

Click to show.

Test Name

K8sDatapathConfig Host firewall With VXLAN

Failure Output

FAIL: Failed to reach 192.168.56.11:80 from testclient-vcslw

Jenkins URL: https://jenkins.cilium.io/job/Cilium-PR-K8s-1.24-kernel-5.4/1624/

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

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

Click to show.

Test Name

K8sDatapathConfig Etcd Check connectivity

Failure Output

FAIL: Found 1 io.cilium/app=operator logs matching list of errors that must be investigated:

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

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.

@jibi
Copy link
Member Author

jibi commented Apr 6, 2023

/test-1.24-5.4

@jibi
Copy link
Member Author

jibi commented Apr 6, 2023

/test-1.26-net-next

@jibi jibi added the ready-to-merge This PR has passed all tests and received consensus from code owners to merge. label Apr 6, 2023
@squeed squeed merged commit d714db7 into v1.13 Apr 6, 2023
37 checks passed
@squeed squeed deleted the pr/v1.13-backport-2023-04-05 branch April 6, 2023 10:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport/1.13 This PR represents a backport for Cilium 1.13.x of a PR that was merged to main. kind/backports This PR provides functionality previously merged into master. ready-to-merge This PR has passed all tests and received consensus from code owners to merge.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

8 participants