Manila HNAS driver allows managing a share twice

Bug #1613683 reported by Alyson
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Shared File Systems Service (Manila)
Fix Released
Undecided
Alyson

Bug Description

In Manila HNAS driver, is possible to manage a share twice passing its name with a colon:

manila manage --name test1 --share-type hds ubuntu@hnas#Hitachi nfs 172.24.49.26:/shares/f5b21612-9841-42c8-bec4-ca32ba70a9ae

and

manila manage --name test2 --share-type hds ubuntu@hnas#Hitachi nfs 172.24.49.26:/shares/f5b21612-9841-42c8-bec4-ca32ba70a9ae:1

It will manage test1 and test2 to same share in backend causing inconsistency in Manila.

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

Fix proposed to branch: master
Review: https://review.openstack.org/355906

Changed in manila:
assignee: nobody → Alyson (alyson-rodrigues-rosa)
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to manila (master)

Reviewed: https://review.openstack.org/355906
Committed: https://git.openstack.org/cgit/openstack/manila/commit/?id=12f95b1373dad7b1a9201fb009093051fa2f8755
Submitter: Jenkins
Branch: master

commit 12f95b1373dad7b1a9201fb009093051fa2f8755
Author: Alyson Rosa <email address hidden>
Date: Tue Aug 16 09:19:42 2016 -0300

    Fix Manila HNAS driver managing a share twice

    Manila HNAS driver splits the path to manage a share by ':', so when
    passing a path with two colons the last part is ignored, it causes the
    possibility to manage a share twice. For example:

    manila manage --name test1 --share-type hds ubuntu@hnas#Hitachi nfs
    172.24.49.26:/shares/f5b21612-9841-42c8-bec4-ca32ba70a9ae

    and

    manila manage --name test2 --share-type hds ubuntu@hnas#Hitachi nfs
    172.24.49.26:/shares/f5b21612-9841-42c8-bec4-ca32ba70a9ae:1

    Changing the split to search for ':/shares/' prevents a share to be
    managed twice.

    Change-Id: Ie97f749d7093db69a757db7c04041f6f649c7ce9
    Closes-Bug: #1613683

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

This issue was fixed in the openstack/manila 3.0.0.0b3 development milestone.

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

Fix proposed to branch: stable/mitaka
Review: https://review.openstack.org/368007

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to manila (stable/mitaka)

Reviewed: https://review.openstack.org/368007
Committed: https://git.openstack.org/cgit/openstack/manila/commit/?id=c89d627e44d29ab64be7b092d9c3ed5b043d79aa
Submitter: Jenkins
Branch: stable/mitaka

commit c89d627e44d29ab64be7b092d9c3ed5b043d79aa
Author: Alyson Rosa <email address hidden>
Date: Tue Aug 16 09:19:42 2016 -0300

    Fix Manila HNAS driver managing a share twice

    Manila HNAS driver splits the path to manage a share by ':', so when
    passing a path with two colons the last part is ignored, it causes the
    possibility to manage a share twice. For example:

    manila manage --name test1 --share-type hds ubuntu@hnas#Hitachi nfs
    172.24.49.26:/shares/f5b21612-9841-42c8-bec4-ca32ba70a9ae

    and

    manila manage --name test2 --share-type hds ubuntu@hnas#Hitachi nfs
    172.24.49.26:/shares/f5b21612-9841-42c8-bec4-ca32ba70a9ae:1

    Changing the split to search for ':/shares/' prevents a share to be
    managed twice.

    Conflicts:
            manila/share/drivers/hitachi/hds_hnas.py
            manila/tests/share/drivers/hitachi/hnas/test_driver.py

    Change-Id: Ie97f749d7093db69a757db7c04041f6f649c7ce9
    Closes-Bug: #1613683
    (cherry picked from commit 12f95b1373dad7b1a9201fb009093051fa2f8755)

tags: added: in-stable-mitaka
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.