div8cn opened a new issue #4433:
URL: https://github.com/apache/cloudstack/issues/4433


   <!--
   Verify first that your issue/request is not already reported on GitHub.
   Also test if the latest release and master branch are affected too.
   Always add information AFTER of these HTML comments, but no need to delete 
the comments.
   -->
   
   ##### ISSUE TYPE
   <!-- Pick one below and delete the rest -->
    * Bug Report
   
   
   ##### COMPONENT NAME
   <!--
   Categorize the issue, e.g. API, VR, VPN, UI, etc.
   -->
   ~~~
   snapshot
   ~~~
   
   ##### CLOUDSTACK VERSION
   <!--
   New line separated list of affected versions, commit ID for issues on master 
branch.
   -->
   
   ~~~
   4.14.0.0
   ~~~
   
   ##### CONFIGURATION
   <!--
   Information about the configuration if relevant, e.g. basic network, 
advanced networking, etc.  N/A otherwise
   -->
   
   
   ##### OS / ENVIRONMENT
   <!--
   Information about the environment if relevant, N/A otherwise
   -->
   CentOS 7.7 KVM QEMU 2.12.0,libvirt 4.5.0
   Ceph 14.2.10
   
   ##### SUMMARY
   <!-- Explain the problem/feature briefly -->
   
   
   snapshot.backup.to.secondary=false
   kvm.snapshot.enabled=true
   
   
   When creating a new VOLUME through a VOLUME snapshot,
   Only the first snapshot of each VOLUME is successful;
   No other snapshots of the same VOLUME can create a new VOLUME
   
   "Path" is missing from CopyCommand: 
"snapshots/2/5445/4e130b18-a495-4220-8c8d-118d186e961f"
   
   CopyCommand:
   {
        "org.apache.cloudstack.storage.command.CopyCommand": {
                "srcTO": {
                        "org.apache.cloudstack.storage.to.SnapshotObjectTO": {
                                "volume": {
                                        "uuid": 
"8c39f2f5-9b18-494e-b990-969d9318eeff",
                                        "volumeType": "ROOT",
                                        "dataStore": {
                                                
"org.apache.cloudstack.storage.to.PrimaryDataStoreTO": {
                                                        "uuid": 
"049f30ad-d4ec-33cb-a0e3-e34df5f2f757",
                                                        "id": 2,
                                                        "poolType": "RBD",
                                                        "host": 
"10.226.15.3,10.226.15.4,10.226.15.5",
                                                        "path": "cloudstack",
                                                        "port": 6789,
                                                        "url": 
"RBD://10.226.15.3,10.226.15.4,10.226.15.5/cloudstack/?ROLE=Primary&STOREUUID=049f30ad-d4ec-33cb-a0e3-e34df5f2f757",
                                                        "isManaged": false
                                                }
                                        },
                                        "name": "ROOT-4158",
                                        "size": 107374182400,
                                        "path": 
"8c39f2f5-9b18-494e-b990-969d9318eeff",
                                        "volumeId": 5445,
                                        "vmName": "i-2-4158-VM",
                                        "accountId": 2,
                                        "format": "QCOW2",
                                        "provisioningType": "THIN",
                                        "id": 5445,
                                        "deviceId": 0,
                                        "hypervisorType": "KVM",
                                        "directDownload": false
                                },
                                "dataStore": {
                                        "com.cloud.agent.api.to.NfsTO": {
                                                "_url": 
"nfs://10.226.15.21/nfs/secstorage",
                                                "_role": "Image"
                                        }
                                },
                                "vmName": "i-2-4158-VM",
                                "name": "aaaaa2",
                                "hypervisorType": "KVM",
                                "id": 27345,
                                "quiescevm": false,
                                "physicalSize": 0
                        }
                },
                "destTO": {
                        "org.apache.cloudstack.storage.to.VolumeObjectTO": {
                                "uuid": "32cc7365-9bc3-49c5-87f1-871a96fb0bf7",
                                "volumeType": "DATADISK",
                                "dataStore": {
                                        
"org.apache.cloudstack.storage.to.PrimaryDataStoreTO": {
                                                "uuid": 
"049f30ad-d4ec-33cb-a0e3-e34df5f2f757",
                                                "id": 2,
                                                "poolType": "RBD",
                                                "host": 
"10.226.15.3,10.226.15.4,10.226.15.5",
                                                "path": "cloudstack",
                                                "port": 6789,
                                                "url": 
"RBD://10.226.15.3,10.226.15.4,10.226.15.5/cloudstack/?ROLE=Primary&STOREUUID=049f30ad-d4ec-33cb-a0e3-e34df5f2f757",
                                                "isManaged": false
                                        }
                                },
                                "name": "aaaaa2-Volume",
                                "size": 107374182400,
                                "volumeId": 5447,
                                "accountId": 2,
                                "format": "QCOW2",
                                "provisioningType": "THIN",
                                "id": 5447,
                                "hypervisorType": "KVM",
                                "directDownload": false
                        }
                },
                "executeInSequence": false,
                "options": {},
                "options2": {},
                "wait": 10800
        }
   }
   
   Log:
   
   2020-10-28 09:03:55,535 WARN  [o.a.c.s.d.ObjectInDataStoreManagerImpl] 
(API-Job-Executor-1:ctx-d3f6d1cd job-127275 ctx-f465d613) (logid:91387467) 
Unsupported data object (VOLUME, 
org.apache.cloudstack.storage.datastore.PrimaryDataStoreImpl@2b441866), no need 
to delete from object in store ref table
   2020-10-28 09:03:55,539 DEBUG [o.a.c.e.o.VolumeOrchestrator] 
(API-Job-Executor-1:ctx-d3f6d1cd job-127275 ctx-f465d613) (logid:91387467) 
Failed to create volume from snapshot:java.lang.NullPointerException
        at 
com.cloud.hypervisor.kvm.storage.KVMStorageProcessor.createVolumeFromSnapshot(KVMStorageProcessor.java:1599)
        at 
com.cloud.storage.resource.StorageSubsystemCommandHandlerBase.execute(StorageSubsystemCommandHandlerBase.java:110)
        at 
com.cloud.storage.resource.StorageSubsystemCommandHandlerBase.handleStorageCommands(StorageSubsystemCommandHandlerBase.java:57)
        at 
com.cloud.hypervisor.kvm.resource.wrapper.LibvirtStorageSubSystemCommandWrapper.execute(LibvirtStorageSubSystemCommandWrapper.java:36)
        at 
com.cloud.hypervisor.kvm.resource.wrapper.LibvirtStorageSubSystemCommandWrapper.execute(LibvirtStorageSubSystemCommandWrapper.java:30)
        at 
com.cloud.hypervisor.kvm.resource.wrapper.LibvirtRequestWrapper.execute(LibvirtRequestWrapper.java:89)
        at 
com.cloud.hypervisor.kvm.resource.LibvirtComputingResource.executeRequest(LibvirtComputingResource.java:1665)
        at com.cloud.agent.Agent.processRequest(Agent.java:644)
        at com.cloud.agent.Agent$AgentRequestHandler.doTask(Agent.java:1069)
        at com.cloud.utils.nio.Task.call(Task.java:83)
        at com.cloud.utils.nio.Task.call(Task.java:29)
        at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
        at 
java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
        at 
java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
        at java.base/java.lang.Thread.run(Thread.java:834)
   
   ##### STEPS TO REPRODUCE
   <!--
   For bugs, show exactly how to reproduce the problem, using a minimal 
test-case. Use Screenshots if accurate.
   
   For new features, show how the feature would be used.
   -->
   
   <!-- Paste example playbooks or commands between quotes below -->
   ~~~
   1. Create a VOLUME snapshot;
   2. Create VOLUME from the volume snapshot (successful);
   3. Create a VOLUME snapshot;
   4. Create VOLUME from volume snapshot (failure);
   
   ~~~
   
   <!-- You can also paste gist.github.com links for larger files -->
   
   ##### EXPECTED RESULTS
   <!-- What did you expect to happen when running the steps above? -->
   
   ~~~
   1. Create a VOLUME snapshot;
   2. Create VOLUME from the volume snapshot (successful);
   3. Create a VOLUME snapshot;
   4. Create VOLUME from volume snapshot (successful);
   ~~~
   
   ##### ACTUAL RESULTS
   <!-- What actually happened? -->
   
   <!-- Paste verbatim command output between quotes below -->
   ~~~
   
   ~~~
   


----------------------------------------------------------------
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.

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


Reply via email to