After live migrating a volume into the 3PAR driver the volume would be
unusable. And we would no longer be able to do any operation with it.
Migrated in-use volumes cannot be renamed when migrated and therefore
need to use the "_name_id" field of the Volume object (volumes table in
the DB) to store the original volume's ID so the driver can locate the
volume.
The problem is that, even though the 3PAR driver sets the "_name_id"
field, it doesn't use it for any operation, so once the volume has been
migrated and the ID of the volume no longer matches the one that was
used to create the volume (value now in "_name_id") it will no longer be
able to locate the volume.
This patch adds the logic necessary to locate volumes using the
"_name_id" field.
Closes-Bug: #1697422
Change-Id: I27b9d4be419e1b52db02d4525b292ceeb5d5f867
(cherry picked from commit fc51678298a38dcd94bcfe92c590b38fdb7193e4)
Reviewed: https:/ /review. opendev. org/736303 /git.openstack. org/cgit/ openstack/ cinder/ commit/ ?id=cfde6bd1c01 29de86ce123c157 42d948624b478f
Committed: https:/
Submitter: Zuul
Branch: stable/train
commit cfde6bd1c0129de 86ce123c15742d9 48624b478f
Author: Gorka Eguileor <email address hidden>
Date: Tue May 19 14:01:13 2020 +0200
3PAR: Fix live migration
After live migrating a volume into the 3PAR driver the volume would be
unusable. And we would no longer be able to do any operation with it.
Migrated in-use volumes cannot be renamed when migrated and therefore
need to use the "_name_id" field of the Volume object (volumes table in
the DB) to store the original volume's ID so the driver can locate the
volume.
The problem is that, even though the 3PAR driver sets the "_name_id"
field, it doesn't use it for any operation, so once the volume has been
migrated and the ID of the volume no longer matches the one that was
used to create the volume (value now in "_name_id") it will no longer be
able to locate the volume.
This patch adds the logic necessary to locate volumes using the
"_name_id" field.
Closes-Bug: #1697422 52db02d4525b292 ceeb5d5f867 d94bcfe92c590b3 8fdb7193e4)
Change-Id: I27b9d4be419e1b
(cherry picked from commit fc51678298a38dc