You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cloudstack.apache.org by Vadim Kimlaychuk <Va...@Elion.ee> on 2014/10/06 14:10:38 UTC
CS 4.4.0 and XenServer 6.2. Stopping VM destroys it.
Hello,
Have found very unplesent behaviour : when I execute „stop instance“ command Cloudstack actually destroys VM from hypervisor. No errors or other warnings has been issued. Management log shows:
2014-10-06 14:55:37,365 DEBUG [c.c.a.t.Request] (Work-Job-Executor-70:ctx-ea29a5b5 job-158/job-159 ctx-65d35099) Seq 1-1867586470475218798: Sending { Cmd , MgmtId: 90520745720479, via: 1(xcp1), Ver: v1, Flags: 100011, [{"com.cloud.agent.api.StopCommand":{"isProxy":false,"executeInSequence":false,"checkBeforeCleanup":false,"vmName":"i-2-13-VM","wait":0}}] }
2014-10-06 14:55:37,365 DEBUG [c.c.a.t.Request] (Work-Job-Executor-70:ctx-ea29a5b5 job-158/job-159 ctx-65d35099) Seq 1-1867586470475218798: Executing: { Cmd , MgmtId: 90520745720479, via: 1(xcp1), Ver: v1, Flags: 100011, [{"com.cloud.agent.api.StopCommand":{"isProxy":false,"executeInSequence":false,"checkBeforeCleanup":false,"vmName":"i-2-13-VM","wait":0}}] }
……
Then shortly after that:
2014-10-06 14:56:24,867 DEBUG [c.c.h.x.r.CitrixResourceBase] (DirectAgent-282:ctx-29a6d080) 10. The VM i-2-13-VM is in Stopped state
But when I go to XEN dom0 and run „xe vm-list“ there is no VM anymore. And I can’t obviously start it again. Shows error “Job failed due to exception Unable to create a deployment for VM[User|i-2-13-VM]“
Is it a bug or what?
Vadim Kimlaychuk
integratsiooni arhitekt
tel. 640 2297
mob. 5233474
RE: CS 4.4.0 and XenServer 6.2. Stopping VM destroys it.
Posted by Vadim Kimlaychuk <Va...@Elion.ee>.
You are right, CS tries to re-create VM, but fails with this:
-------------------------------------------------------------------------------------------
2014-10-06 15:08:59,447 DEBUG [c.c.d.DeploymentPlanningManagerImpl] (Work-Job-Executor-71:ctx-57f37864 job-160/job-161 ctx-377bdf08) This VM has last host_id specified, trying to choose the same host: 1
2014-10-06 15:08:59,449 DEBUG [c.c.d.DeploymentPlanningManagerImpl] (Work-Job-Executor-71:ctx-57f37864 job-160/job-161 ctx-377bdf08) The last host of this VM is in avoid set
2014-10-06 15:08:59,449 DEBUG [c.c.d.DeploymentPlanningManagerImpl] (Work-Job-Executor-71:ctx-57f37864 job-160/job-161 ctx-377bdf08) Cannot choose the last host to deploy this VM
2014-10-06 15:08:59,449 DEBUG [c.c.d.FirstFitPlanner] (Work-Job-Executor-71:ctx-57f37864 job-160/job-161 ctx-377bdf08) Searching resources only under specified Pod: 1
2014-10-06 15:08:59,449 DEBUG [c.c.d.FirstFitPlanner] (Work-Job-Executor-71:ctx-57f37864 job-160/job-161 ctx-377bdf08) Listing clusters in order of aggregate capacity, that have (atleast one host with) enough CPU and RAM capacity under this Pod: 1
2014-10-06 15:08:59,455 DEBUG [c.c.d.FirstFitPlanner] (Work-Job-Executor-71:ctx-57f37864 job-160/job-161 ctx-377bdf08) Removing from the clusterId list these clusters from avoid set: [1]
2014-10-06 15:08:59,456 DEBUG [c.c.d.FirstFitPlanner] (Work-Job-Executor-71:ctx-57f37864 job-160/job-161 ctx-377bdf08) No clusters found after removing disabled clusters and clusters in avoid list, returning.
2014-10-06 15:08:59,506 DEBUG [c.c.c.CapacityManagerImpl] (Work-Job-Executor-71:ctx-57f37864 job-160/job-161 ctx-377bdf08) VM state transitted from :Starting to Stopped with event: OperationFailedvm's original host id: 1 new host id: null host id before state transition: null
2014-10-06 15:08:59,542 ERROR [c.c.v.VmWorkJobHandlerProxy] (Work-Job-Executor-71:ctx-57f37864 job-160/job-161 ctx-377bdf08) Invocation exception, caused by: com.cloud.exception.InsufficientServerCapacityException: Unable to create a deployment for VM[User|i-2-13-VM]Scope=interface com.cloud.dc.DataCenter; id=1
2014-10-06 15:08:59,542 INFO [c.c.v.VmWorkJobHandlerProxy] (Work-Job-Executor-71:ctx-57f37864 job-160/job-161 ctx-377bdf08) Rethrow exception com.cloud.exception.InsufficientServerCapacityException: Unable to create a deployment for VM[User|i-2-13-VM]Scope=interface com.cloud.dc.DataCenter; id=1
2014-10-06 15:08:59,542 DEBUG [c.c.v.VmWorkJobDispatcher] (Work-Job-Executor-71:ctx-57f37864 job-160/job-161) Done with run of VM work job: com.cloud.vm.VmWorkStart for VM 13, job origin: 160
2014-10-06 15:08:59,542 ERROR [c.c.v.VmWorkJobDispatcher] (Work-Job-Executor-71:ctx-57f37864 job-160/job-161) Unable to complete AsyncJobVO {id:161, userId: 2, accountId: 2, instanceType: null, instanceId: null, cmd: com.cloud.vm.VmWorkStart, cmdInfo: rO0ABXNyABhjb20uY2xvdWQudm0uVm1Xb3JrU3RhcnR9cMGsvxz73gIAC0oABGRjSWRMAAZhdm9pZHN0ADBMY29tL2Nsb3VkL2RlcGxveS9EZXBsb3ltZW50UGxhbm5lciRFeGNsdWRlTGlzdDtMAAljbHVzdGVySWR0ABBMamF2YS9sYW5nL0xvbmc7TAAGaG9zdElkcQB-AAJMAAtqb3VybmFsTmFtZXQAEkxqYXZhL2xhbmcvU3RyaW5nO0wAEXBoeXNpY2FsTmV0d29ya0lkcQB-AAJMAAdwbGFubmVycQB-AANMAAVwb2RJZHEAfgACTAAGcG9vbElkcQB-AAJMAAlyYXdQYXJhbXN0AA9MamF2YS91dGlsL01hcDtMAA1yZXNlcnZhdGlvbklkcQB-AAN4cgATY29tLmNsb3VkLnZtLlZtV29ya5-ZtlbwJWdrAgAESgAJYWNjb3VudElkSgAGdXNlcklkSgAEdm1JZEwAC2hhbmRsZXJOYW1lcQB-AAN4cAAAAAAAAAACAAAAAAAAAAIAAAAAAAAADXQAGVZpcnR1YWxNYWNoaW5lTWFuYWdlckltcGwAAAAAAAAAAHBwcHBwcHBwc3IAEWphdmEudXRpbC5IYXNoTWFwBQfawcMWYNEDAAJGAApsb2FkRmFjdG9ySQAJdGhyZXNob2xkeHA_QAAAAAAADHcIAAAAEAAAAAF0AApWbVBhc3N3b3JkdAAcck8wQUJYUUFEbk5oZG1Wa1gzQmhjM04zYjNKa3hw, cmdVersion: 0, status: IN_PROGRESS, processStatus: 0, resultCode: 0, result: null, initMsid: 90520745720479, completeMsid: null, lastUpdated: null, lastPolled: null, created: Mon Oct 06 15:08:58 EEST 2014}, job origin:160
com.cloud.exception.InsufficientServerCapacityException: Unable to create a deployment for VM[User|i-2-13-VM]Scope=interface com.cloud.dc.DataCenter; id=1
at com.cloud.vm.VirtualMachineManagerImpl.orchestrateStart(VirtualMachineManagerImpl.java:946)
at com.cloud.vm.VirtualMachineManagerImpl.orchestrateStart(VirtualMachineManagerImpl.java:5190)
at sun.reflect.GeneratedMethodAccessor195.invoke(Unknown Source)
------------------------------------------------
Strange - I have enough resources to create it from the scratch. Why does it different for "stop-start" ?
The second thing that I am worry -- "The last host of this VM is in avoid set ". May be this is the reason of failure?
Vadim.
-----Original Message-----
From: Erik Weber [mailto:terbolous@gmail.com]
Sent: Monday, October 06, 2014 3:28 PM
To: users@cloudstack.apache.org
Subject: Re: CS 4.4.0 and XenServer 6.2. Stopping VM destroys it.
On Mon, Oct 6, 2014 at 2:10 PM, Vadim Kimlaychuk <Va...@elion.ee>
wrote:
> Hello,
>
> Have found very unplesent behaviour : when I execute „stop
> instance“ command Cloudstack actually destroys VM from hypervisor. No
> errors or other warnings has been issued.
AFAIK that is normal, you don't need the VM definition on the hypervisor, CloudStack will recreate it when needed.
> Management log shows:
>
> 2014-10-06 14:55:37,365 DEBUG [c.c.a.t.Request]
> (Work-Job-Executor-70:ctx-ea29a5b5 job-158/job-159 ctx-65d35099) Seq
> 1-1867586470475218798: Sending { Cmd , MgmtId: 90520745720479, via:
> 1(xcp1), Ver: v1, Flags: 100011,
> [{"com.cloud.agent.api.StopCommand":{"isProxy":false,"executeInSequenc
> e":false,"checkBeforeCleanup":false,"vmName":"i-2-13-VM","wait":0}}]
> }
> 2014-10-06 14:55:37,365 DEBUG [c.c.a.t.Request]
> (Work-Job-Executor-70:ctx-ea29a5b5 job-158/job-159 ctx-65d35099) Seq
> 1-1867586470475218798: Executing: { Cmd , MgmtId: 90520745720479, via:
> 1(xcp1), Ver: v1, Flags: 100011,
> [{"com.cloud.agent.api.StopCommand":{"isProxy":false,"executeInSequenc
> e":false,"checkBeforeCleanup":false,"vmName":"i-2-13-VM","wait":0}}]
> }
>
> ……
>
> Then shortly after that:
> 2014-10-06 14:56:24,867 DEBUG [c.c.h.x.r.CitrixResourceBase]
> (DirectAgent-282:ctx-29a6d080) 10. The VM i-2-13-VM is in Stopped
> state
>
> But when I go to XEN dom0 and run „xe vm-list“ there is no VM anymore.
> And I can’t obviously start it again. Shows error “Job failed due to
> exception Unable to create a deployment for VM[User|i-2-13-VM]“
>
Could you get more log output as to why it fails to create a deployment?
Best is to tail the log 1 second before you hit launch, and paste the log content on pastebin after the exception occurs.
--
Erik
RE: CS 4.4.0 and XenServer 6.2. Stopping VM destroys it.
Posted by Geoff Higginbottom <ge...@shapeblue.com>.
To clarify..
When XenServer is being used with CloudStack it behaves differently than a standalone XenServer.
When a VM is running, it is shown in XenCenter or when listed via XE commands etc.
However when you stop a VM, as far as XenServer is concerned it has been destroyed, with only the Volumes left behind on Storage.
This may sound like a strange way of doing things but it makes sense when you consider that when CloudStack starts a VM, it does all sorts of configuration as changes could have been made whilst the VM is off such as:
Add or Remove NICs
Add or Remove Storage / IOS
Change CPU/RAM (via compute offering)
Change Affinity Groups
The Hypervisor which will run the VM is only chosen when the VM starts, so any Hypervisor with access to the Shared Storage for the Cluster could start the VM.
Regards
Geoff Higginbottom
D: +44 20 3603 0542 | S: +44 20 3603 0540 | M: +447968161581
geoff.higginbottom@shapeblue.com
-----Original Message-----
From: Erik Weber [mailto:terbolous@gmail.com]
Sent: 06 October 2014 13:28
To: users@cloudstack.apache.org
Subject: Re: CS 4.4.0 and XenServer 6.2. Stopping VM destroys it.
On Mon, Oct 6, 2014 at 2:10 PM, Vadim Kimlaychuk <Va...@elion.ee>
wrote:
> Hello,
>
> Have found very unplesent behaviour : when I execute „stop
> instance“ command Cloudstack actually destroys VM from hypervisor. No
> errors or other warnings has been issued.
AFAIK that is normal, you don't need the VM definition on the hypervisor, CloudStack will recreate it when needed.
> Management log shows:
>
> 2014-10-06 14:55:37,365 DEBUG [c.c.a.t.Request]
> (Work-Job-Executor-70:ctx-ea29a5b5 job-158/job-159 ctx-65d35099) Seq
> 1-1867586470475218798: Sending { Cmd , MgmtId: 90520745720479, via:
> 1(xcp1), Ver: v1, Flags: 100011,
> [{"com.cloud.agent.api.StopCommand":{"isProxy":false,"executeInSequenc
> e":false,"checkBeforeCleanup":false,"vmName":"i-2-13-VM","wait":0}}]
> }
> 2014-10-06 14:55:37,365 DEBUG [c.c.a.t.Request]
> (Work-Job-Executor-70:ctx-ea29a5b5 job-158/job-159 ctx-65d35099) Seq
> 1-1867586470475218798: Executing: { Cmd , MgmtId: 90520745720479, via:
> 1(xcp1), Ver: v1, Flags: 100011,
> [{"com.cloud.agent.api.StopCommand":{"isProxy":false,"executeInSequenc
> e":false,"checkBeforeCleanup":false,"vmName":"i-2-13-VM","wait":0}}]
> }
>
> ……
>
> Then shortly after that:
> 2014-10-06 14:56:24,867 DEBUG [c.c.h.x.r.CitrixResourceBase]
> (DirectAgent-282:ctx-29a6d080) 10. The VM i-2-13-VM is in Stopped
> state
>
> But when I go to XEN dom0 and run „xe vm-list“ there is no VM anymore.
> And I can’t obviously start it again. Shows error “Job failed due to
> exception Unable to create a deployment for VM[User|i-2-13-VM]“
>
Could you get more log output as to why it fails to create a deployment?
Best is to tail the log 1 second before you hit launch, and paste the log content on pastebin after the exception occurs.
--
Erik
Find out more about ShapeBlue and our range of CloudStack related services
IaaS Cloud Design & Build<http://shapeblue.com/iaas-cloud-design-and-build//>
CSForge – rapid IaaS deployment framework<http://shapeblue.com/csforge/>
CloudStack Consulting<http://shapeblue.com/cloudstack-consultancy/>
CloudStack Infrastructure Support<http://shapeblue.com/cloudstack-infrastructure-support/>
CloudStack Bootcamp Training Courses<http://shapeblue.com/cloudstack-training/>
This email and any attachments to it may be confidential and are intended solely for the use of the individual to whom it is addressed. Any views or opinions expressed are solely those of the author and do not necessarily represent those of Shape Blue Ltd or related companies. If you are not the intended recipient of this email, you must neither take any action based upon its contents, nor copy or show it to anyone. Please contact the sender if you believe you have received this email in error. Shape Blue Ltd is a company incorporated in England & Wales. ShapeBlue Services India LLP is a company incorporated in India and is operated under license from Shape Blue Ltd. Shape Blue Brasil Consultoria Ltda is a company incorporated in Brasil and is operated under license from Shape Blue Ltd. ShapeBlue SA Pty Ltd is a company registered by The Republic of South Africa and is traded under license from Shape Blue Ltd. ShapeBlue is a registered trademark.
Re: CS 4.4.0 and XenServer 6.2. Stopping VM destroys it.
Posted by Erik Weber <te...@gmail.com>.
On Mon, Oct 6, 2014 at 2:10 PM, Vadim Kimlaychuk <Va...@elion.ee>
wrote:
> Hello,
>
> Have found very unplesent behaviour : when I execute „stop
> instance“ command Cloudstack actually destroys VM from hypervisor. No
> errors or other warnings has been issued.
AFAIK that is normal, you don't need the VM definition on the hypervisor,
CloudStack will recreate it when needed.
> Management log shows:
>
> 2014-10-06 14:55:37,365 DEBUG [c.c.a.t.Request]
> (Work-Job-Executor-70:ctx-ea29a5b5 job-158/job-159 ctx-65d35099) Seq
> 1-1867586470475218798: Sending { Cmd , MgmtId: 90520745720479, via:
> 1(xcp1), Ver: v1, Flags: 100011,
> [{"com.cloud.agent.api.StopCommand":{"isProxy":false,"executeInSequence":false,"checkBeforeCleanup":false,"vmName":"i-2-13-VM","wait":0}}]
> }
> 2014-10-06 14:55:37,365 DEBUG [c.c.a.t.Request]
> (Work-Job-Executor-70:ctx-ea29a5b5 job-158/job-159 ctx-65d35099) Seq
> 1-1867586470475218798: Executing: { Cmd , MgmtId: 90520745720479, via:
> 1(xcp1), Ver: v1, Flags: 100011,
> [{"com.cloud.agent.api.StopCommand":{"isProxy":false,"executeInSequence":false,"checkBeforeCleanup":false,"vmName":"i-2-13-VM","wait":0}}]
> }
>
> ……
>
> Then shortly after that:
> 2014-10-06 14:56:24,867 DEBUG [c.c.h.x.r.CitrixResourceBase]
> (DirectAgent-282:ctx-29a6d080) 10. The VM i-2-13-VM is in Stopped state
>
> But when I go to XEN dom0 and run „xe vm-list“ there is no VM anymore.
> And I can’t obviously start it again. Shows error “Job failed due to
> exception Unable to create a deployment for VM[User|i-2-13-VM]“
>
Could you get more log output as to why it fails to create a deployment?
Best is to tail the log 1 second before you hit launch, and paste the log
content on pastebin after the exception occurs.
--
Erik