You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cloudstack.apache.org by fi...@sina.com on 2014/08/14 10:04:31 UTC

cannot create template

The envirionment is cloudstack4.0.0+vmware5.0.There was an error when i 
created a template.The following is my procedure:
1. stop the instance
2. click the "create template" button on the website of the root disk of the instance.
Then there was an error.The following is the errorlog of mangement-server:
2014-07-29 22:02:28,113 DEBUG [agent.transport.Request] (AgentManager-Handler-4:null) Seq 12-916361029: Processing:  { Ans: , MgmtId: 345049268249, via: 12, Ver: v1, Flags: 10, [{"storage.CreatePrivateTemplateAnswer":{"_virtualSize":0,"_physicalSize":0,"result":false,"details":"CreatePrivateTemplateFromVolumeCommand exception: java.lang.NullPointerException\ncom.cloud.hypervisor.vmware.mo.HostMO.getVmPropertiesOnHyperHost(HostMO.java:586)\ncom.cloud.hypervisor.vmware.mo.HostMO.loadVmCache(HostMO.java:485)\ncom.cloud.hypervisor.vmware.mo.HostMO.findVmOnHyperHost(HostMO.java:475)\ncom.cloud.hypervisor.vmware.manager.VmwareStorageManagerImpl.execute(VmwareStorageManagerImpl.java:264)\ncom.cloud.storage.resource.VmwareSecondaryStorageResourceHandler.execute(VmwareSecondaryStorageResourceHandler.java:121)\ncom.cloud.storage.resource.VmwareSecondaryStorageResourceHandler.executeRequest(VmwareSecondaryStorageResourceHandler.java:73)\ncom.cloud.storage.resource.PremiumSecondaryStorageResource.executeRequest(PremiumSecondaryStorageResource.java:54)\ncom.cloud.agent.Agent.processRequest(Agent.java:518)\ncom.cloud.agent.Agent$AgentRequestHandler.doTask(Agent.java:831)\ncom.cloud.utils.nio.Task.run(Task.java:83)\njava.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)\njava.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)\njava.lang.Thread.run(Thread.java:662)\n","wait":0}}] }
2014-07-29 22:02:28,114 DEBUG [agent.transport.Request] (Job-Executor-20:job-200) Seq 12-916361029: Received:  { Ans: , MgmtId: 345049268249, via: 12, Ver: v1, Flags: 10, { CreatePrivateTemplateAnswer } }
2014-07-29 22:02:28,140 ERROR [cloud.api.ApiDispatcher] (Job-Executor-20:job-200) Exception while executing CreateTemplateCmd:
com.cloud.utils.exception.CloudRuntimeException: Failed to create a template
        at com.cloud.vm.UserVmManagerImpl.createPrivateTemplate(UserVmManagerImpl.java:1662)
        at com.cloud.utils.component.ComponentLocator$InterceptorDispatcher.intercept(ComponentLocator.java:1231)
        at com.cloud.vm.UserVmManagerImpl.createPrivateTemplate(UserVmManagerImpl.java:237)
        at com.cloud.api.commands.CreateTemplateCmd.execute(CreateTemplateCmd.java:265)
        at com.cloud.api.ApiDispatcher.dispatch(ApiDispatcher.java:138)
        at com.cloud.async.AsyncJobManagerImpl$1.run(AsyncJobManagerImpl.java:432)
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
        at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
        at java.util.concurrent.FutureTask.run(FutureTask.java:166)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
        at java.lang.Thread.run(Thread.java:679)
2014-07-29 22:02:28,141 DEBUG [cloud.async.AsyncJobManagerImpl] (Job-Executor-20:job-200) Complete async job-200, jobStatus: 2, resultCode: 530, result: Error Code: 530 Error text: Failed to create a template

Re: cannot create template

Posted by Nitin Mehta <Ni...@citrix.com>.
There is NPE in the answer right ? Vmware resource throws that
{"storage.CreatePrivateTemplateAnswer":{"_virtualSize":0,"_physicalSize":0,
"result":false,"details":"CreatePrivateTemplateFromVolumeCommand
exception: 
java.lang.NullPointerException\ncom.cloud.hypervisor.vmware.mo.HostMO.getVm
PropertiesOnHyperHost(HostMO.java:586)\ncom.cloud.hypervisor.vmware.mo.Host
MO.loadVmCache(HostMO.java:485)\ncom.cloud.hypervis


Thanks,
-Nitin

On 14/08/14 4:08 PM, "ilya musayev" <il...@gmail.com> wrote:

>Please check if convert to template job timed out.
>Also, if you see an error in vCenter when template created, please post
>it here. You may need to pull out hostd.log from the hypervisor that the
>command was executed on.
>
>Template generation maybe a slow process for vmware in general -
>depending on your storage setup.
>
>Have you tried using 4.3?
>
>
>On 8/14/14, 1:04 AM, fight3000dz@sina.com wrote:
>> The envirionment is cloudstack4.0.0+vmware5.0.There was an error when i
>> created a template.The following is my procedure:
>> 1. stop the instance
>> 2. click the "create template" button on the website of the root disk
>>of the instance.
>> Then there was an error.The following is the errorlog of
>>mangement-server:
>> 2014-07-29 22:02:28,113 DEBUG [agent.transport.Request]
>>(AgentManager-Handler-4:null) Seq 12-916361029: Processing:  { Ans: ,
>>MgmtId: 345049268249, via: 12, Ver: v1, Flags: 10,
>>[{"storage.CreatePrivateTemplateAnswer":{"_virtualSize":0,"_physicalSize"
>>:0,"result":false,"details":"CreatePrivateTemplateFromVolumeCommand
>>exception: 
>>java.lang.NullPointerException\ncom.cloud.hypervisor.vmware.mo.HostMO.get
>>VmPropertiesOnHyperHost(HostMO.java:586)\ncom.cloud.hypervisor.vmware.mo.
>>HostMO.loadVmCache(HostMO.java:485)\ncom.cloud.hypervisor.vmware.mo.HostM
>>O.findVmOnHyperHost(HostMO.java:475)\ncom.cloud.hypervisor.vmware.manager
>>.VmwareStorageManagerImpl.execute(VmwareStorageManagerImpl.java:264)\ncom
>>.cloud.storage.resource.VmwareSecondaryStorageResourceHandler.execute(Vmw
>>areSecondaryStorageResourceHandler.java:121)\ncom.cloud.storage.resource.
>>VmwareSecondaryStorageResourceHandler.executeRequest(VmwareSecondaryStora
>>geResourceHandler.java:73)\ncom.cloud.storage.resource.PremiumSecondarySt
>>orageResource.executeRequest(PremiumSecondaryStorageResource.java:54)\nco
>>m.cloud.agent.Agent.processRequest(Agent.java:518)\ncom.cloud.agent.Agent
>>$AgentRequestHandler.doTask(Agent.java:831)\ncom.cloud.utils.nio.Task.run
>>(Task.java:83)\njava.util.concurrent.ThreadPoolExecutor$Worker.runTask(Th
>>readPoolExecutor.java:886)\njava.util.concurrent.ThreadPoolExecutor$Worke
>>r.run(ThreadPoolExecutor.java:908)\njava.lang.Thread.run(Thread.java:662)
>>\n","wait":0}}] }
>> 2014-07-29 22:02:28,114 DEBUG [agent.transport.Request]
>>(Job-Executor-20:job-200) Seq 12-916361029: Received:  { Ans: , MgmtId:
>>345049268249, via: 12, Ver: v1, Flags: 10, { CreatePrivateTemplateAnswer
>>} }
>> 2014-07-29 22:02:28,140 ERROR [cloud.api.ApiDispatcher]
>>(Job-Executor-20:job-200) Exception while executing CreateTemplateCmd:
>> com.cloud.utils.exception.CloudRuntimeException: Failed to create a
>>template
>>          at 
>>com.cloud.vm.UserVmManagerImpl.createPrivateTemplate(UserVmManagerImpl.ja
>>va:1662)
>>          at 
>>com.cloud.utils.component.ComponentLocator$InterceptorDispatcher.intercep
>>t(ComponentLocator.java:1231)
>>          at 
>>com.cloud.vm.UserVmManagerImpl.createPrivateTemplate(UserVmManagerImpl.ja
>>va:237)
>>          at 
>>com.cloud.api.commands.CreateTemplateCmd.execute(CreateTemplateCmd.java:2
>>65)
>>          at com.cloud.api.ApiDispatcher.dispatch(ApiDispatcher.java:138)
>>          at 
>>com.cloud.async.AsyncJobManagerImpl$1.run(AsyncJobManagerImpl.java:432)
>>          at 
>>java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
>>          at 
>>java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
>>          at java.util.concurrent.FutureTask.run(FutureTask.java:166)
>>          at 
>>java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java
>>:1110)
>>          at 
>>java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.jav
>>a:603)
>>          at java.lang.Thread.run(Thread.java:679)
>> 2014-07-29 22:02:28,141 DEBUG [cloud.async.AsyncJobManagerImpl]
>>(Job-Executor-20:job-200) Complete async job-200, jobStatus: 2,
>>resultCode: 530, result: Error Code: 530 Error text: Failed to create a
>>template
>
>


Re: cannot create template

Posted by ilya musayev <il...@gmail.com>.
Please check if convert to template job timed out.
Also, if you see an error in vCenter when template created, please post 
it here. You may need to pull out hostd.log from the hypervisor that the 
command was executed on.

Template generation maybe a slow process for vmware in general - 
depending on your storage setup.

Have you tried using 4.3?


On 8/14/14, 1:04 AM, fight3000dz@sina.com wrote:
> The envirionment is cloudstack4.0.0+vmware5.0.There was an error when i
> created a template.The following is my procedure:
> 1. stop the instance
> 2. click the "create template" button on the website of the root disk of the instance.
> Then there was an error.The following is the errorlog of mangement-server:
> 2014-07-29 22:02:28,113 DEBUG [agent.transport.Request] (AgentManager-Handler-4:null) Seq 12-916361029: Processing:  { Ans: , MgmtId: 345049268249, via: 12, Ver: v1, Flags: 10, [{"storage.CreatePrivateTemplateAnswer":{"_virtualSize":0,"_physicalSize":0,"result":false,"details":"CreatePrivateTemplateFromVolumeCommand exception: java.lang.NullPointerException\ncom.cloud.hypervisor.vmware.mo.HostMO.getVmPropertiesOnHyperHost(HostMO.java:586)\ncom.cloud.hypervisor.vmware.mo.HostMO.loadVmCache(HostMO.java:485)\ncom.cloud.hypervisor.vmware.mo.HostMO.findVmOnHyperHost(HostMO.java:475)\ncom.cloud.hypervisor.vmware.manager.VmwareStorageManagerImpl.execute(VmwareStorageManagerImpl.java:264)\ncom.cloud.storage.resource.VmwareSecondaryStorageResourceHandler.execute(VmwareSecondaryStorageResourceHandler.java:121)\ncom.cloud.storage.resource.VmwareSecondaryStorageResourceHandler.executeRequest(VmwareSecondaryStorageResourceHandler.java:73)\ncom.cloud.storage.resource.PremiumSecondaryStorageResource.executeRequest(PremiumSecondaryStorageResource.java:54)\ncom.cloud.agent.Agent.processRequest(Agent.java:518)\ncom.cloud.agent.Agent$AgentRequestHandler.doTask(Agent.java:831)\ncom.cloud.utils.nio.Task.run(Task.java:83)\njava.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)\njava.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)\njava.lang.Thread.run(Thread.java:662)\n","wait":0}}] }
> 2014-07-29 22:02:28,114 DEBUG [agent.transport.Request] (Job-Executor-20:job-200) Seq 12-916361029: Received:  { Ans: , MgmtId: 345049268249, via: 12, Ver: v1, Flags: 10, { CreatePrivateTemplateAnswer } }
> 2014-07-29 22:02:28,140 ERROR [cloud.api.ApiDispatcher] (Job-Executor-20:job-200) Exception while executing CreateTemplateCmd:
> com.cloud.utils.exception.CloudRuntimeException: Failed to create a template
>          at com.cloud.vm.UserVmManagerImpl.createPrivateTemplate(UserVmManagerImpl.java:1662)
>          at com.cloud.utils.component.ComponentLocator$InterceptorDispatcher.intercept(ComponentLocator.java:1231)
>          at com.cloud.vm.UserVmManagerImpl.createPrivateTemplate(UserVmManagerImpl.java:237)
>          at com.cloud.api.commands.CreateTemplateCmd.execute(CreateTemplateCmd.java:265)
>          at com.cloud.api.ApiDispatcher.dispatch(ApiDispatcher.java:138)
>          at com.cloud.async.AsyncJobManagerImpl$1.run(AsyncJobManagerImpl.java:432)
>          at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
>          at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
>          at java.util.concurrent.FutureTask.run(FutureTask.java:166)
>          at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
>          at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
>          at java.lang.Thread.run(Thread.java:679)
> 2014-07-29 22:02:28,141 DEBUG [cloud.async.AsyncJobManagerImpl] (Job-Executor-20:job-200) Complete async job-200, jobStatus: 2, resultCode: 530, result: Error Code: 530 Error text: Failed to create a template