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
fix: statle smb mount issue when smb file share is deleted and then unmount #121851
fix: statle smb mount issue when smb file share is deleted and then unmount #121851
Conversation
/kind bug |
@jsafrane can you take a look? thanks. |
/lgtm |
LGTM label has been added. Git tree hash: b211ee78f42277554b58605565bcd967226a3441
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: andyzhangx, jsafrane The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
…121851-upstream-release-1.26 Automated cherry pick of #121851: fix: smb file share unavailable issue when it's deleted
…121851-upstream-release-1.28 Automated cherry pick of #121851: fix: smb file share unavailable issue when it's deleted
…121851-upstream-release-1.27 Automated cherry pick of #121851: fix: smb file share unavailable issue when it's deleted
this issue is fixed in v1.26.13, v1.27.10, v1.28.6, v1.29.0 |
What type of PR is this?
/kind bug
What this PR does / why we need it:
fix: statle smb mount issue when smb file share is deleted and then unmount
there is behavior change from linux kernel
5.15.0-1051-azure
(or earlier version), when smb file share is deleted, the upstream mount-utils depends on following logic to check whether smb mount is in stale state, while starting from the former kernel version, it returnsresource temporarily unavailable
error instead ofErrNotExist
, thus this PR tries to add a new judgement in the mount-utils inIsCorruptedMnt
func, hereEWOULDBLOCK
isresource temporarily unavailable
error.original logic (won't work now since it now returns it returns
resource temporarily unavailable
error instead ofErrNotExist
in kernel)kubernetes/staging/src/k8s.io/mount-utils/mount_helper_unix.go
Lines 188 to 198 in a95a79c
currunt error message is like following:
workaround
force delete the pod
impact
This issue does not only break CSI drivers, it also breaks on pods with subPath smb volume, error msg is like following, this requires a patch version fix of kubelet since subPath unmount does not go through CSI driver.
Which issue(s) this PR fixes:
Fixes #
Special notes for your reviewer:
Does this PR introduce a user-facing change?
Additional documentation e.g., KEPs (Kubernetes Enhancement Proposals), usage docs, etc.: