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

fix: remove parent dir in DeleteVolume #770

Merged
merged 2 commits into from
Sep 15, 2024

Conversation

andyzhangx
Copy link
Member

@andyzhangx andyzhangx commented Sep 15, 2024

What type of PR is this?
/kind bug

What this PR does / why we need it:
fix: remove parent dir in DeleteVolume

Which issue(s) this PR fixes:

Fixes #763

Special notes for your reviewer:

[pod/csi-nfs-controller-67c56ff89f-j244d/nfs] I0915 05:01:30.363893       1 utils.go:110] GRPC call: /csi.v1.Controller/DeleteVolume
[pod/csi-nfs-controller-67c56ff89f-j244d/nfs] I0915 05:01:30.364289       1 utils.go:111] GRPC request: {"secrets":"***stripped***","volume_id":"nfs-server.default.svc.cluster.local##nfs-7869/pvc-m74ps#pvc-f2772f7e-a91c-4b0e-83d5-9cb0b3da9998#"}
[pod/csi-nfs-controller-67c56ff89f-j244d/nfs] I0915 05:01:30.364360       1 controllerserver.go:225] DeleteVolume: found mountOptions(nfsvers=4.1) for volume(nfs-server.default.svc.cluster.local##nfs-7869/pvc-m74ps#pvc-f2772f7e-a91c-4b0e-83d5-9cb0b3da9998#)
[pod/csi-nfs-controller-67c56ff89f-j244d/nfs] I0915 05:01:30.364550       1 controllerserver.go:502] internally mounting nfs-server.default.svc.cluster.local:/ at /tmp/pvc-f2772f7e-a91c-4b0e-83d5-9cb0b3da9998
[pod/csi-nfs-controller-67c56ff89f-j244d/nfs] I0915 05:01:30.364894       1 nodeserver.go:132] NodePublishVolume: volumeID(nfs-server.default.svc.cluster.local##nfs-7869/pvc-m74ps#pvc-f2772f7e-a91c-4b0e-83d5-9cb0b3da9998#) source(nfs-server.default.svc.cluster.local:/) targetPath(/tmp/pvc-f2772f7e-a91c-4b0e-83d5-9cb0b3da9998) mountflags([nfsvers=4.1])
[pod/csi-nfs-controller-67c56ff89f-j244d/nfs] I0915 05:01:30.364925       1 mount_linux.go:218] Mounting cmd (mount) with arguments (-t nfs -o nfsvers=4.1 nfs-server.default.svc.cluster.local:/ /tmp/pvc-f2772f7e-a91c-4b0e-83d5-9cb0b3da9998)
[pod/csi-nfs-controller-67c56ff89f-j244d/nfs] I0915 05:01:30.394775       1 nodeserver.go:149] skip chmod on targetPath(/tmp/pvc-f2772f7e-a91c-4b0e-83d5-9cb0b3da9998) since mountPermissions is set as 0
[pod/csi-nfs-controller-67c56ff89f-j244d/nfs] I0915 05:01:30.394816       1 nodeserver.go:151] volume(nfs-server.default.svc.cluster.local##nfs-7869/pvc-m74ps#pvc-f2772f7e-a91c-4b0e-83d5-9cb0b3da9998#) mount nfs-server.default.svc.cluster.local:/ on /tmp/pvc-f2772f7e-a91c-4b0e-83d5-9cb0b3da9998 succeeded
[pod/csi-nfs-controller-67c56ff89f-j244d/nfs] I0915 05:01:30.394905       1 controllerserver.go:301] removing subdirectory at /tmp/pvc-f2772f7e-a91c-4b0e-83d5-9cb0b3da9998/nfs-7869 on internalVolumePath /tmp/pvc-f2772f7e-a91c-4b0e-83d5-9cb0b3da9998/nfs-7869/pvc-m74ps
[pod/csi-nfs-controller-67c56ff89f-j244d/nfs] I0915 05:01:30.396139       1 controllerserver.go:517] internally unmounting /tmp/pvc-f2772f7e-a91c-4b0e-83d5-9cb0b3da9998
[pod/csi-nfs-controller-67c56ff89f-j244d/nfs] I0915 05:01:30.396163       1 nodeserver.go:172] NodeUnpublishVolume: unmounting volume nfs-server.default.svc.cluster.local##nfs-7869/pvc-m74ps#pvc-f2772f7e-a91c-4b0e-83d5-9cb0b3da9998# on /tmp/pvc-f2772f7e-a91c-4b0e-83d5-9cb0b3da9998
[pod/csi-nfs-controller-67c56ff89f-j244d/nfs] I0915 05:01:30.396361       1 nodeserver.go:177] force unmount nfs-server.default.svc.cluster.local##nfs-7869/pvc-m74ps#pvc-f2772f7e-a91c-4b0e-83d5-9cb0b3da9998# on /tmp/pvc-f2772f7e-a91c-4b0e-83d5-9cb0b3da9998
[pod/csi-nfs-controller-67c56ff89f-j244d/nfs] I0915 05:01:30.396408       1 mount_helper_common.go:56] unmounting "/tmp/pvc-f2772f7e-a91c-4b0e-83d5-9cb0b3da9998" (corruptedMount: false, mounterCanSkipMountPointChecks: true)
[pod/csi-nfs-controller-67c56ff89f-j244d/nfs] I0915 05:01:30.396422       1 mount_linux.go:789] Unmounting /tmp/pvc-f2772f7e-a91c-4b0e-83d5-9cb0b3da9998
[pod/csi-nfs-controller-67c56ff89f-j244d/nfs] I0915 05:01:30.422736       1 mount_helper_common.go:150] Deleting path "/tmp/pvc-f2772f7e-a91c-4b0e-83d5-9cb0b3da9998"
[pod/csi-nfs-controller-67c56ff89f-j244d/nfs] I0915 05:01:30.423299       1 nodeserver.go:185] NodeUnpublishVolume: unmount volume nfs-server.default.svc.cluster.local##nfs-7869/pvc-m74ps#pvc-f2772f7e-a91c-4b0e-83d5-9cb0b3da9998# on /tmp/pvc-f2772f7e-a91c-4b0e-83d5-9cb0b3da9998 successfully

Does this PR introduce a user-facing change?:

fix: remove parent dir in DeleteVolume

@k8s-ci-robot k8s-ci-robot added release-note Denotes a PR that will be considered when it comes time to generate release notes. kind/bug Categorizes issue or PR as related to a bug. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. labels Sep 15, 2024
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: andyzhangx

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 /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added approved Indicates a PR has been approved by an approver from all required OWNERS files. size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Sep 15, 2024
@coveralls
Copy link

coveralls commented Sep 15, 2024

Pull Request Test Coverage Report for Build 10868018354

Details

  • 10 of 12 (83.33%) changed or added relevant lines in 2 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage decreased (-0.003%) to 78.117%

Changes Missing Coverage Covered Lines Changed/Added Lines %
pkg/nfs/controllerserver.go 6 8 75.0%
Totals Coverage Status
Change from base Build 10866816642: -0.003%
Covered Lines: 921
Relevant Lines: 1179

💛 - Coveralls

@andyzhangx andyzhangx merged commit 0961635 into kubernetes-csi:master Sep 15, 2024
17 of 18 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. kind/bug Categorizes issue or PR as related to a bug. release-note Denotes a PR that will be considered when it comes time to generate release notes. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Clean up empty parents on deletion when using subDir
3 participants