Bug 2101692

Summary: [GSS] Unable to delete the rbd image although no snapshot is attached
Product: [Red Hat Storage] Red Hat OpenShift Data Foundation Reporter: Priya Pandey <prpandey>
Component: cephAssignee: Ilya Dryomov <idryomov>
ceph sub component: RBD QA Contact: Neha Berry <nberry>
Status: CLOSED NOTABUG Docs Contact:
Severity: medium    
Priority: unspecified CC: assingh, bniver, csharpe, hnallurv, idryomov, mhackett, muagarwa, ocs-bugs, odf-bz-bot, pnataraj, smulay
Version: 4.9   
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2023-03-22 11:11:33 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Priya Pandey 2022-06-28 07:15:52 UTC
Description of problem (please be detailed as possible and provide log
snippets):

- Cu is unable to delete the rbd image although there's no snapshot linked: 

rbd trash rm replica-2-rbd/ba35df8c2e6fdb
rbd: remove error: 2022-06-08T12:46:56.431+0000 7fb78524a2c0 -1 librbd::api::Trash: remove: error getting image id ba35df8c2e6fdb info from trash: (2) No such file or directory
(2) No such file or directory
Removing image: 0% complete...failed.

- We tried to purge the snapshot but it doesn't list any snapshot:


sh-4.4$ rbd snap ls replica-2-rbd/csi-vol-008b435a-c698-11ec-8d12-0a580a800226-temp
sh-4.4$ rbd snap purge replica-2-rbd/csi-vol-008b435a-c698-11ec-8d12-0a580a800226-temp

sh-4.4$ rbd -p replica-2-rbd rm csi-vol-008b435a-c698-11ec-8d12-0a580a800226-temp
2022-06-08T12:48:37.439+0000 7f80d690f2c0 -1 librbd::api::Image: remove: image has snapshots - not removing
Removing image: 0% complete...failed.
rbd: image has snapshots with linked clones - these must be deleted or flattened before the image can be removed.

Version of all relevant components (if applicable):
v4.9

Does this issue impact your ability to continue to work with the product
(please explain in detail what is the user impact)?

- Cu wants to remove the unwanted rbd images from the cluster.

Is there any workaround available to the best of your knowledge?

N/A

Rate from 1 - 5 the complexity of the scenario you performed that caused this
bug (1 - very simple, 5 - very complex)?
N/A

Can this issue be reproducible?
N/A

Can this issue reproduce from the UI?
N/A

If this is a regression, please provide more details to justify this:
N/A

Steps to Reproduce:
N/A

Actual results:

- Unable to delete the RBD image from the cluster.

Expected results:

- Unable to delete the RBD image from the cluster

Additional info:

In the next comments