Share server migration fails to reuse network allocations and use wrong vserver_name

Bug #2064907 reported by Sylvan Le Deunff
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Shared File Systems Service (Manila)
Fix Committed
Undecided
Sylvan Le Deunff

Bug Description

ISSUE 1
=======
When performing a share server migration, if no new network is specified same allocations should be reused on destination share server.

But the code responsible to update existing allocations with new share_server_id seems to be missing here:
https://opendev.org/openstack/manila/src/tag/18.1.0/manila/share/manager.py#L6099

ISSUE 2
=======
The way share server name is retrieved in NetApp driver prevents doing another migration after the first one.

- NetApp driver determines the name of the source share server for a migration using templating (something like "os_{server_id}" by default).
- Migration of NetApp vserver with manila creates a new share_server entry in manila DB with a different server_id, but vserver still has the same name on NetApp cluster.
- Now the name "os_{server_id}" does not match "vserver_name" anymore.
- This breaks ability to migrate vserver a second time.

The problem occurs in those functions related to migration:
- _check_for_migration_support: https://opendev.org/openstack/manila/src/tag/18.1.0/manila/share/drivers/netapp/dataontap/cluster_mode/lib_multi_svm.py#L1286
- _migration_start_using_svm_migrate: https://opendev.org/openstack/manila/src/tag/18.1.0/manila/share/drivers/netapp/dataontap/cluster_mode/lib_multi_svm.py#L1525

And can be fixed by replacing templating by using backend_details stored in manila
- source_share_server["backend_details"]["vserver_name"]

description: updated
description: updated
description: updated
Changed in manila:
assignee: nobody → Sylvan Le Deunff (sylvanld)
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/+/918297

Changed in manila:
status: New → In Progress
Vida Haririan (vhariria)
tags: added: migration share-migration
Changed in manila:
status: In Progress → Fix Committed
Revision history for this message
Sylvan Le Deunff (sylvanld) wrote :

Hello! It there a status for this bug ? It seems to have been discussed in triage meeting but importance is not set and no milestone is defined :)

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.