Drivers need more information to ensure snapshots of a replicated share across replicas

Bug #1546303 reported by Goutham Pacha Ravi
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Shared File Systems Service (Manila)
Fix Released
High
Alex Meade

Bug Description

Currently, the create and delete snapshot interfaces do not pass in any of the replica information. As with the rest of the replica methods, these interfaces need to pass the share_replicas to the drivers to aid them in ensuring that a snapshot being created is actually created (or mirrored) across the replicas.

Tags: netapp cdot zfs
Changed in manila:
assignee: nobody → Goutham Pacha Ravi (gouthamr)
Alex Meade (alex-meade)
Changed in manila:
status: New → In Progress
tags: added: cdot netapp
tags: added: zfs
Revision history for this message
Goutham Pacha Ravi (gouthamr) wrote :

We realize that the design of the existing snapshot interfaces cannot handle snapshot instances that are required to track snapshots across replicas -> so instead of shoving more information in the existing interfaces, we need new interfaces.

Changed in manila:
milestone: none → mitaka-rc1
importance: Undecided → High
status: In Progress → Triaged
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/292659

Changed in manila:
status: Triaged → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix proposed to manila (master)

Related fix proposed to branch: master
Review: https://review.openstack.org/293113

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/293243

Changed in manila:
assignee: Goutham Pacha Ravi (gouthamr) → Alex Meade (alex-meade)
Changed in manila:
assignee: Alex Meade (alex-meade) → Goutham Pacha Ravi (gouthamr)
Changed in manila:
assignee: Goutham Pacha Ravi (gouthamr) → Alex Meade (alex-meade)
Changed in manila:
assignee: Alex Meade (alex-meade) → Goutham Pacha Ravi (gouthamr)
Changed in manila:
assignee: Goutham Pacha Ravi (gouthamr) → Alex Meade (alex-meade)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to manila (master)

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

commit 94e04c8de20a842725e47042418cff818e6f7515
Author: Goutham Pacha Ravi <email address hidden>
Date: Thu Mar 3 22:48:15 2016 -0500

    Data Replication: Ensure Snapshots across replicas

    When taking a snapshot of a replicated share, users would
    expect the snapshot to be available across the replicas.
    Currently, Manila assumes that drivers will take snapshots
    along with the share data.

    Different backends implement replication differently. Many
    of them assume that replicas are 'in_sync' with the primary
    if they have been synchronized within a particular window
    of time (sometimes referred to as 'recovery point objective').
    Since snapshots are point in time actions on a share, drivers
    must ensure that the replication of a snapshot begins as soon
    as it is available on the primary/'active' instance.

    To ensure that snapshots are indeed available across replicas:
    1) Track snapshots across replicas as different
        snapshot instances.
    2) Make an 'aggregate_status' property to convey the
        availability of a snapshot across all the active/in_sync
        replicas of a share.
    3) Provide all the information necessary for drivers to:
        - Create a snapshot on the primary and send it across
           to all replicas
        - Delete a snapshot on the primary and ensure that it is
           deleted on the replicas as well.
    4) Set snapshot instance to 'error' if it was in any transitional
        state when its replica was 'promoted' to become an 'active'
        instance.
    5) Pass down snapshot instances during create, delete and update
    replica driver calls.
    6) Update replica interfaces to pass in snapshot instance data. Always
    include 'available' snapshots in the update_replica call to ensure
    that drivers confirm their presence on the replica in order to report
    that the replica is 'in_sync'.

    Also, grab the share_type afresh from parent share/snapshot
    to allow 'replication_key' to be copied to the share model during
    share creation.

    Rename SnapshotNotFound to SnapshotResourceNotFound to
    signify a missing snapshot object on backends.

    APIImpact
    The 'status' attribute of the snapshot is now the 'aggregate_status'
    of the instances of the snapshot. No key changes have been made
    in the JSON response. However, API actions will be gated against
    'aggregate_status' of the snapshot instances when more than one
    instance exists.

    Closes-Bug: #1546303
    Closes-Bug: #1551064

    Change-Id: I63203df00904d209e9e92eda7c79206e5ef8d611

Changed in manila:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix merged to manila (master)

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

commit 430a18b50ce83bcb5112dd13cee23814f26334ef
Author: Alex Meade <email address hidden>
Date: Mon Mar 7 16:18:12 2016 -0500

    NetApp cDOT: Handle replicated snapshots

    This patch implements the following driver methods
    required for replicated snapshots to be handled correctly.
    create_replicated_snapshot
    delete_replicated_snapshot
    update_replicated_snapshot

    Closes-Bug: #1557071
    Related-Bug: #1546303

    Change-Id: Ia4cd2a36e31418e7a3d1c218080caa632755fe16

Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

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

commit b161889e3209921a06eee4ec6e1ec2377d1250ba
Author: Valeriy Ponomaryov <email address hidden>
Date: Tue Mar 15 20:43:20 2016 +0200

    Make ZFSonLinux driver handle snapshots of replicated shares properly

    With this fix it is now possible to
    - replicate share created from snapshot.
    - create share from snapshot after "promote replica" action.

    Change-Id: Id318a4adc0faf64a4bef57252aa2f0d9083b82b1
    Depends-On: I63203df00904d209e9e92eda7c79206e5ef8d611
    Closes-Bug: #1557283
    Related-Bug: #1546303

Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

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

commit 7bf4f0262e99d5deffa292565c5a80ee50638d36
Author: Yogesh <email address hidden>
Date: Tue Sep 29 23:41:02 2015 -0400

    Add tests to ensure snapshots across replicas

    Related-Bug: #1546303
    Depends-On: Ia4cd2a36e31418e7a3d1c218080caa632755fe16
    Depends-On: Id318a4adc0faf64a4bef57252aa2f0d9083b82b1
    Change-Id: I269225b976efe13b2cbb9e0648d541a063df70e5

Revision history for this message
Doug Hellmann (doug-hellmann) wrote : Fix included in openstack/manila 2.0.0.0rc1

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

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/manila 2.0.0

This issue was fixed in the openstack/manila 2.0.0 release.

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.