HNAS driver is always handling mountable snapshots, even if mount_snapshot_support=False

Bug #1660421 reported by Rodrigo Barbieri
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Shared File Systems Service (Manila)
Fix Released
Low
Rodrigo Barbieri

Bug Description

For upgraded environments, the HNAS driver is always attempting to delete snapshot exports when deleting a snapshot. Although it swallows the exception because the export does not exist, this attempt it certain to fail, and it could be avoided by checking if the snapshot has mount_snapshot_support before trying to delete the snapshot. See below:

2017-01-30 13:34:11.969 ERROR manila.share.drivers.hitachi.hnas.ssh [req-fa1d0cf8-40d4-45d3-b34d-13bf9f446a72 6a08846c319c4ae5aa3c09402e88a450 649c607e28c244d2b58b22840c2214af] Error running SSH command.
2017-01-30 13:34:11.970 WARNING manila.share.drivers.hitachi.hnas.ssh [req-fa1d0cf8-40d4-45d3-b34d-13bf9f446a72 6a08846c319c4ae5aa3c09402e88a450 649c607e28c244d2b58b22840c2214af] Export /snapshots/4ac1e629-0caa-4d21-b44a-bee5f95621ce does not exist on backend anymore.

It is also always creating export resources in the backend even if mount_snapshot_support=False when creating snapshots.

description: updated
Changed in manila:
importance: Undecided → Low
milestone: none → ocata-rc1
summary: - HNAS driver always tries to delete export, even if snapshot is not
- mountable
+ HNAS driver is always handling mountable snapshots, even if
+ mount_snapshot_support=False
description: updated
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/428077

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

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

commit c4b65df374562540f83f6478e51ce2f2949aab73
Author: Alyson Rosa <email address hidden>
Date: Wed Feb 1 14:09:32 2017 -0200

    Fix HNAS driver always handling mountable snapshots

    HNAS driver always handles snapshots as if mount_snaphot_support
    is always True.
    The driver always create exports in snapshot_create and tries to
    delete it in snapshot_delete. Also, the driver tries to add rules
    for exports in snapshot_update_access without checking if the export
    exists.

    Fixing it by checking the key 'mount_snapshot_support' in shares and
    checking if the snapshot has an export before adding or removing
    rules.

    Change-Id: If25d68d04400f0e9015f6ad6aff845f9c5d47f94
    Closes-bug: #1660420
    Closes-bug: #1660421

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

This issue was fixed in the openstack/manila 4.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.