Browse Source

Changes to correct name of missing NetApp license.

Change to have the NetApp ZAPI error of "SIS clone not licensed"
refer to the correct NetApp license of "FlexClone not licensed".
This code path is encountered when the NetApp 7mode driver uses
the clone interface for snapshotting or cloning.

Change-Id: I3e4d07d38870928a324ad044e03938826b0d0a98
Closes-Bug: #1295349
tags/2014.1.rc1
Glenn M. Gobeli 5 years ago
parent
commit
9920eb9edc
1 changed files with 8 additions and 3 deletions
  1. 8
    3
      cinder/volume/drivers/netapp/api.py

+ 8
- 3
cinder/volume/drivers/netapp/api.py View File

@@ -26,6 +26,8 @@ from cinder.openstack.common import log as logging
26 26
 
27 27
 LOG = logging.getLogger(__name__)
28 28
 
29
+ESIS_CLONE_NOT_LICENSED = '14956'
30
+
29 31
 
30 32
 class NaServer(object):
31 33
     """Encapsulates server connection logic."""
@@ -214,9 +216,12 @@ class NaServer(object):
214 216
         code = result.get_attr('errno')\
215 217
             or result.get_child_content('errorno')\
216 218
             or 'ESTATUSFAILED'
217
-        msg = result.get_attr('reason')\
218
-            or result.get_child_content('reason')\
219
-            or 'Execution status is failed due to unknown reason'
219
+        if code == ESIS_CLONE_NOT_LICENSED:
220
+            msg = 'Clone operation failed: FlexClone not licensed.'
221
+        else:
222
+            msg = result.get_attr('reason')\
223
+                or result.get_child_content('reason')\
224
+                or 'Execution status is failed due to unknown reason'
220 225
         raise NaApiError(code, msg)
221 226
 
222 227
     def _create_request(self, na_element, enable_tunneling=False):

Loading…
Cancel
Save