piyush5netapp commented on code in PR #13053:
URL: https://github.com/apache/cloudstack/pull/13053#discussion_r3208821315


##########
engine/storage/volume/src/main/java/org/apache/cloudstack/storage/volume/VolumeServiceImpl.java:
##########
@@ -1340,6 +1340,15 @@ private void 
createManagedVolumeCopyTemplateAsync(VolumeInfo volumeInfo, Primary
             primaryDataStore.setDetails(details);
 
             grantAccess(volumeInfo, destHost, primaryDataStore);
+            volumeInfo = volFactory.getVolume(volumeInfo.getId(), 
primaryDataStore);
+            // For Netapp ONTAP iscsiName or Lun path  is available only after 
grantAccess
+            String managedStoreTarget = volumeInfo.get_iScsiName() != null ? 
volumeInfo.get_iScsiName() : volumeInfo.getUuid();
+            details.put(PrimaryDataStore.MANAGED_STORE_TARGET, 
managedStoreTarget);
+            primaryDataStore.setDetails(details);
+            // Update destTemplateInfo with the iSCSI path from volumeInfo
+            if (destTemplateInfo instanceof TemplateObject) {
+                
((TemplateObject)destTemplateInfo).setInstallPath(volumeInfo.getPath());

Review Comment:
   @winterhazel  I have removed this code as even if we don't setInstallPath 
explicitly, derivePath under KVMStorageProcessor use the managedStoreTarget 
value as installPath, which is we also need. 



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to