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

Possible leaks in cephcsi (question) #2059

Open
Madhu-1 opened this issue May 7, 2021 · 7 comments
Open

Possible leaks in cephcsi (question) #2059

Madhu-1 opened this issue May 7, 2021 · 7 comments
Assignees
Labels
component/cephfs Issues related to CephFS component/rbd Issues related to RBD component/util Utility functions shared between CephFS and RBD keepalive This label can be used to disable stale bot activiity in the repo Priority-0 highest priority issue question Further information is requested

Comments

@Madhu-1
Copy link
Collaborator

Madhu-1 commented May 7, 2021

Possible leaks in cephcsi (question)

General leak

CreateVolume/CreateSnapshot

  • we create a new UUID entry in the omap and we add a mapping between the new UUID and PV Name and we go ahead and create the volume

What if the csi pod is restarted between the new UUID and PV mapping? will this leave a stale entry?

Note: We also need to check restart of csi-provisioner container will leave any stale PVC,PV,ceph resource in cluster?

RBD

Create Volume

  • Reserve omap
    • Possible leak as mentioned in the general section?
  • Create rbd image

Create volume from the snapshot

  • Reserve omap and create a clone from the snapshot already created
  • Only the omap leak can occur

Create Volume from volume

  • Reserve omap
    • Possible leak as mentioned in the general problem?
  • Create snapshot from rbd image
  • Create temp clone from rbd image
    • what if there is a csi pod restart here, is this handled?
  • Check flatten is required and add a task to flatten the image
      • what if there is a csi pod restart here, is this handled?
  • remove the snapshot from the rbd image
    • what if there is a csi pod restart here, is this handled?
    • what if the snapshot cannot be deleted?
  • create a snapshot on temp clone image.
    • what if there is a csi pod restart here, is this handled?
  • create a final clone from temp clone
    • what if there is a csi pod restart here, is this handled?
  • Delete snapshot on the temp clone
    • what if there is a csi pod restart here, is this handled?
    • what if the snapshot cannot be deleted?

Create snapshot

  • Reserve omap
    • Possible leak as mentioned in the general section?
  • Create snapshot from rbd image
  • Create a clone from the rbd image
    • what if there is a csi pod restart here, is this handled?
  • remove the snapshot from the rbd image
    • what if there is a csi pod restart here, is this handled?
    • what if the snapshot removal fails?
  • create a snapshot on clone image.
    • what if there is a csi pod restart here, is this handled?

Delete Volume

Note covered in #1728?

  • Move the image to the trash
    • what if there is a csi pod restart here, is this handled?
  • Add task to remove the image from trash
    • what if there is a csi pod restart here, is this handled?
  • Cleanup omap

CephFS

Create Volume

  • Reserve omap
    • Possible leak as mentioned in the general section?
  • Create subvolume

Create volume from the snapshot

  • Reserve omap
    • Possible leak as mentioned in the general section?
  • create a clone from the snapshot already created

Create Volume from volume

  • Reserve omap
    • Possible leak as mentioned in the general problem?
  • Create snapshot from cephfs subvolume
  • Create a clone from a snapshot
    • what if there is a restart here is this handled?
    • If the clone creation fails and also snapshot deletion fails will this leave a stale snapshot here?
  • If the clone is ready remove the snapshot
    • what if there is a restart here is this handled?
    • what if the snapshot cannot be deleted?

Create snapshot

  • Reserve omap
    • Possible leak as mentioned in the general problem?
  • Create snapshot subvolume
@Madhu-1 Madhu-1 added component/cephfs Issues related to CephFS component/rbd Issues related to RBD component/util Utility functions shared between CephFS and RBD question Further information is requested labels May 7, 2021
@Madhu-1
Copy link
Collaborator Author

Madhu-1 commented May 7, 2021

@nixpanic @ShyamsundarR @humblec @Yuggupta27 @Rakshith-R @yati1998 Do you guys any other possibilities we need to check?

@Madhu-1
Copy link
Collaborator Author

Madhu-1 commented May 7, 2021

cc @agarwal-mudit

@Madhu-1
Copy link
Collaborator Author

Madhu-1 commented May 7, 2021

There may/may not be a leak in above cases but we need to verify and make sure there is no leak

@Madhu-1 Madhu-1 added the Priority-0 highest priority issue label Jun 2, 2021
@Madhu-1 Madhu-1 added this to the release-3.4.0 milestone Jun 2, 2021
@Madhu-1 Madhu-1 assigned Rakshith-R and humblec and unassigned Rakshith-R Jun 18, 2021
@humblec
Copy link
Collaborator

humblec commented Jul 28, 2021

As discussed we have to continue the analysis and get into the completion in upcoming releases. Moving this out of 3.4.0 release.

@humblec humblec removed this from the release-3.4.0 milestone Jul 28, 2021
@github-actions
Copy link

This issue has been automatically marked as stale because it has not had recent activity. It will be closed in a week if no further activity occurs. Thank you for your contributions.

@github-actions github-actions bot added the wontfix This will not be worked on label Aug 27, 2021
@github-actions
Copy link

github-actions bot commented Sep 3, 2021

This issue has been automatically closed due to inactivity. Please re-open if this still requires investigation.

@github-actions github-actions bot closed this as completed Sep 3, 2021
@Rakshith-R Rakshith-R reopened this Sep 6, 2021
@Rakshith-R Rakshith-R added keepalive This label can be used to disable stale bot activiity in the repo and removed wontfix This will not be worked on labels Sep 6, 2021
@humblec humblec added this to the release-3.6 milestone Jan 27, 2022
@humblec
Copy link
Collaborator

humblec commented Apr 1, 2022

@Madhu-1 shall we remove this form the milestone tracker?

@Madhu-1 Madhu-1 removed this from the release-3.6 milestone Apr 1, 2022
@humblec humblec added this to the release-3.7 milestone Apr 1, 2022
@humblec humblec modified the milestones: release-3.7, release-3.7.1 Sep 13, 2022
@humblec humblec added this to the release-3.8 milestone Sep 13, 2022
@Madhu-1 Madhu-1 modified the milestones: release-3.8, release-v3.9 Feb 23, 2023
@nixpanic nixpanic removed this from the release-v3.10.0 milestone Nov 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component/cephfs Issues related to CephFS component/rbd Issues related to RBD component/util Utility functions shared between CephFS and RBD keepalive This label can be used to disable stale bot activiity in the repo Priority-0 highest priority issue question Further information is requested
Projects
None yet
Development

No branches or pull requests

4 participants