rp- commented on code in PR #10132:
URL: https://github.com/apache/cloudstack/pull/10132#discussion_r1933416600


##########
plugins/hypervisors/kvm/src/main/java/com/cloud/hypervisor/kvm/storage/KVMStorageProcessor.java:
##########
@@ -274,6 +274,7 @@ public Answer copyTemplateToPrimaryStorage(final 
CopyCommand cmd) {
 
                 if 
(!storagePoolMgr.connectPhysicalDisk(primaryStore.getPoolType(), 
primaryStore.getUuid(), path, details)) {
                     s_logger.warn("Failed to connect physical disk at path: " 
+ path + ", in storage pool id: " + primaryStore.getUuid());
+                    return new PrimaryStorageDownloadAnswer("Failed to spool 
template disk at path: " + path + ", in storage pool id: " + 
primaryStore.getUuid());

Review Comment:
   Sorry no, that still doesn't work.
   Because now Linstor tries to attach a resource on the agent node, that 
doesn't exist yet.
   Usually this would probably not happen, but the first systemvm template is 
special,
   because on the management server we don't know the size of the template yet, 
so Linstor can't create it
   the volumes there yet and I have to get to the `copyPhysicalDisk` on the 
storageAdaptor code and this
   happens after this `null` path connect (if returned `false`) .
   But now I throw a `CloudRuntimeException` because we don't know the volume 
we are asked for to connect (because it isn't there yet).
   
   So I think to ultimately fix this, we would need to figure out why we don't 
know the size on the management server, when doing the TEMPLATE -> TEMPLATE 
`copyAsync`, because then I could already create the volumes there.



-- 
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: commits-unsubscr...@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to