netapp: shares without backing vserver cannot be deleted without force option

Bug #1964592 reported by Maurice Escher
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Shared File Systems Service (Manila)
Fix Released
Medium
kiran pawar

Bug Description

Hi,

I'm on Xena with NetApp DHSS=true.

Due to whatever reasons I have a share server in error (e.g. CIFS with wrong options) and a related share also in error state.

The backing vserver has not been created (or has been rolled back), but the database objects share server and share (and share instance) are still present.

I expect that I can delete the share, but actually it ends up in error_deleting.

Only mitigation option now is doing force-delete, but that is something I don't hand out to my end users to avoid orphans on the NetApp backend.

I see the following trace https://paste.opendev.org/show/813182/

The behaviour changed with https://opendev.org/openstack/manila/commit/4bcf21eaf1e62b1f98f218a6378420d7332c71c6

Because the vserver is not present, it can not build the client.
I think _get_vserver needs to raise exception.VserverNotFound in case self._get_api_client is failing and delete could proceed.

Do you think this makes sense?

Best regards,
Maurice

Tags: netapp
tags: added: netapp
Changed in manila:
assignee: nobody → Andre Luiz Beltrami Rocha (andrebeltrami)
milestone: none → zed-1
Vida Haririan (vhariria)
Changed in manila:
importance: Undecided → Medium
Revision history for this message
Vida Haririan (vhariria) wrote :
Revision history for this message
Maurice Escher (maurice-escher) wrote :

There is even a cleaner solution I think, looking at lib_single_svm it should use the cluster client to check for vserver existence (self._client.vserver_exists) before building the vserver client

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to manila (master)

Fix proposed to branch: master
Review: https://review.opendev.org/c/openstack/manila/+/835832

Changed in manila:
status: New → In Progress
Changed in manila:
milestone: zed-1 → zed-2
Changed in manila:
milestone: zed-2 → zed-3
Changed in manila:
assignee: Andre Luiz Beltrami Rocha (andrebeltrami) → kiran pawar (kpdev)
Changed in manila:
milestone: zed-3 → zed-rc1
Changed in manila:
milestone: zed-rc1 → antelope-1
Changed in manila:
milestone: antelope-1 → antelope-2
Changed in manila:
milestone: antelope-2 → antelope-3
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to manila (master)

Reviewed: https://review.opendev.org/c/openstack/manila/+/835832
Committed: https://opendev.org/openstack/manila/commit/224d3aa4dda388def5dc45b4ae1fb7ac68d86106
Submitter: "Zuul (22348)"
Branch: master

commit 224d3aa4dda388def5dc45b4ae1fb7ac68d86106
Author: Maurice Escher <email address hidden>
Date: Wed Mar 30 13:41:09 2022 +0000

    NetApp: Disable tunneling in vserver_exists

    When share server is in error state in Manila and backend vserver has
    not been created, there exist entries of share server and shares in
    database. Deletion of share in such case cause share in error_deleting
    state. In order to delete share correctly, we need to fix _get_vserver
    which should check vserver existence before building the vserver
    client.

    Closes-Bug: #1964592
    Change-Id: I1f6b94a7e54403a559a5d77b4d93b939a40e76bf

Changed in manila:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/manila 16.0.0.0rc1

This issue was fixed in the openstack/manila 16.0.0.0rc1 release candidate.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.