Sangeetha Hariharan created CLOUDSTACK-2484:
-----------------------------------------------

             Summary: Object_Store_Refactor - ISO - Not able to deploy a VM 
using an iso.
                 Key: CLOUDSTACK-2484
                 URL: https://issues.apache.org/jira/browse/CLOUDSTACK-2484
             Project: CloudStack
          Issue Type: Bug
      Security Level: Public (Anyone can view this level - this is the default.)
          Components: Management Server
    Affects Versions: 4.2.0
         Environment: Build from object_store
            Reporter: Sangeetha Hariharan
             Fix For: 4.2.0


Object_Store_Refactor - ISO - Not able to deploy a VM using an iso.

Steps to reproduce the problem:

Regiter an ISO.
Deploy a Vm using this ISO by choosing hypervisor as "Xenserver".

Vm deployment fails because deployment planner is looking for a "Vmware" 
cluster to deploy this Vm.

mysql> select * from user_vm where iso_id=204;
+----+--------+--------------+-----------+-------------------+
| id | iso_id | display_name | user_data | update_parameters |
+----+--------+--------------+-----------+-------------------+
|  6 |    204 | test-iso-1   | NULL      |                 1 |
+----+--------+--------------+-----------+-------------------+
1 row in set (0.00 sec)

mysql> select * from vm_instance where id=6;
+----+------------+--------------------------------------+---------------+-------+----------------+-------------+---------------------+--------------------+--------+----------------+---------+--------------+----------+-------------------+----------------------------------------------+------------+---------------+--------------+---------------------+---------------------+---------+------+---------+------------+-----------+---------------------+----------------+-----------------+------------------+------+------+-------+-------+------------+--------------+---------------+
| id | name       | uuid                                 | instance_name | 
state | vm_template_id | guest_os_id | private_mac_address | private_ip_address 
| pod_id | data_center_id | host_id | last_host_id | proxy_id | 
proxy_assign_time | vnc_password                                 | ha_enabled | 
limit_cpu_use | update_count | update_time         | created             | 
removed | type | vm_type | account_id | domain_id | service_offering_id | 
reservation_id | hypervisor_type | disk_offering_id | cpu  | ram  | owner | 
speed | host_name  | display_name | desired_state |
+----+------------+--------------------------------------+---------------+-------+----------------+-------------+---------------------+--------------------+--------+----------------+---------+--------------+----------+-------------------+----------------------------------------------+------------+---------------+--------------+---------------------+---------------------+---------+------+---------+------------+-----------+---------------------+----------------+-----------------+------------------+------+------+-------+-------+------------+--------------+---------------+
|  6 | test-iso-1 | c537e134-fab6-4c1b-8aac-441a032fbbe0 | i-2-6-VM      | 
Error |            204 |         100 | NULL                | NULL               
|   NULL |              1 |    NULL |         NULL |     NULL | NULL            
  | vXvnlGHLmOJD//n+4DQL0xxm74q0knU0o9KjAGuAWZM= |          0 |             0 | 
           1 | 2013-05-14 17:14:31 | 2013-05-14 17:14:31 | NULL    | User | 
User    |          2 |         1 |                   2 | NULL           | 
VMware          |                4 | NULL | NULL | 2     |  1000 | test-iso-1 | 
test-iso-1   | NULL          |
+----+------------+--------------------------------------+---------------+-------+----------------+-------------+---------------------+--------------------+--------+----------------+---------+--------------+----------+-------------------+----------------------------------------------+------------+---------------+--------------+---------------------+---------------------+---------+------+---------+------------+-----------+---------------------+----------------+-----------------+------------------+------+------+-------+-------+------------+--------------+---------------+
1 row in set (0.00 sec)


management server logs:

2013-05-14 10:14:31,619 DEBUG [cloud.async.AsyncJobManagerImpl] 
(catalina-exec-20:null) submit async job-20, details: AsyncJobVO {id:20, 
userId: 2, acc
ountId: 2, sessionKey: null, instanceType: VirtualMachine, instanceId: 6, cmd: 
org.apache.cloudstack.api.command.user.vm.DeployVMCmd, cmdOriginator: nu
ll, cmdInfo: 
{"sessionkey":"X/K09rgZ+YIUuGYkv7UGa0FoBEc\u003d","ctxUserId":"2","serviceOfferingId":"93b8728a-bcb6-42c9-a9da-a091737ce6c8","httpmethod":
"GET","zoneId":"a281057d-2a6a-47c1-ab05-f36a20006129","response":"json","templateId":"dcec8151-8066-43a5-a5fa-97a23861129f","id":"6","networkIds":"1e06
97c0-8c52-4af2-b3c3-43d643797864","hypervisor":"XenServer","diskOfferingId":"ca22455f-b277-47cc-a4ae-47fb9dda15da","name":"test-iso-1","_":"13685550902
71","ctxAccountId":"2","ctxStartEventId":"70","displayname":"test-iso-1"}, 
cmdVersion: 0, callbackType: 0, callbackAddress: null, status: 0, processSta
tus: 0, resultCode: 0, result: null, initMsid: 206915885079359, completeMsid: 
null, lastUpdated: null, lastPolled: null, created: null}
2013-05-14 10:14:31,620 DEBUG [cloud.async.AsyncJobManagerImpl] 
(Job-Executor-22:job-20) Executing 
org.apache.cloudstack.api.command.user.vm.DeployVMCm
d for job-20
2013-05-14 10:14:31,622 DEBUG [cloud.api.ApiServlet] (catalina-exec-20:null) 
===END===  10.217.252.128 -- GET  command=deployVirtualMachine&zoneId=a281
057d-2a6a-47c1-ab05-f36a20006129&templateId=dcec8151-8066-43a5-a5fa-97a23861129f&hypervisor=XenServer&serviceOfferingId=93b8728a-bcb6-42c9-a9da-a091737
ce6c8&diskOfferingId=ca22455f-b277-47cc-a4ae-47fb9dda15da&networkIds=1e0697c0-8c52-4af2-b3c3-43d643797864&displayname=test-iso-1&name=test-iso-1&respon
se=json&sessionkey=X%2FK09rgZ%2BYIUuGYkv7UGa0FoBEc%3D&_=1368555090271
2013-05-14 10:14:31,626 DEBUG [cloud.api.ApiDispatcher] 
(Job-Executor-22:job-20) InfrastructureEntity name 
is:com.cloud.offering.ServiceOffering
2013-05-14 10:14:31,628 DEBUG [cloud.api.ApiDispatcher] 
(Job-Executor-22:job-20) ControlledEntity name 
is:com.cloud.template.VirtualMachineTemplate
2013-05-14 10:14:31,630 DEBUG [cloud.api.ApiDispatcher] 
(Job-Executor-22:job-20) ControlledEntity name is:com.cloud.network.Network
2013-05-14 10:14:31,633 DEBUG [cloud.api.ApiDispatcher] 
(Job-Executor-22:job-20) InfrastructureEntity name 
is:com.cloud.offering.DiskOffering
2013-05-14 10:14:31,660 DEBUG [cloud.network.NetworkModelImpl] 
(Job-Executor-22:job-20) Service SecurityGroup is not supported in the network 
id=204
2013-05-14 10:14:31,663 DEBUG [cloud.network.NetworkModelImpl] 
(Job-Executor-22:job-20) Service SecurityGroup is not supported in the network 
id=204
2013-05-14 10:14:31,670 DEBUG [cloud.deploy.DeploymentPlanningManagerImpl] 
(Job-Executor-22:job-20) Deploy avoids pods: null, clusters: null, hosts: nu
ll
2013-05-14 10:14:31,671 DEBUG [cloud.deploy.FirstFitPlanner] 
(Job-Executor-22:job-20) DeploymentPlanner allocation algorithm: random
2013-05-14 10:14:31,671 DEBUG [cloud.deploy.FirstFitPlanner] 
(Job-Executor-22:job-20) Trying to allocate a host and storage pools from dc:1, 
pod:null,cluster:null, requested cpu: 1000, requested ram: 1073741824
2013-05-14 10:14:31,671 DEBUG [cloud.deploy.FirstFitPlanner] 
(Job-Executor-22:job-20) Is ROOT volume READY (pool already allocated)?: No
2013-05-14 10:14:31,671 DEBUG [cloud.deploy.FirstFitPlanner] 
(Job-Executor-22:job-20) Searching all possible resources under this Zone: 1
2013-05-14 10:14:31,672 DEBUG [cloud.deploy.FirstFitPlanner] 
(Job-Executor-22:job-20) Listing clusters in order of aggregate capacity, that 
have (atleast one host with) enough CPU and RAM capacity under this Zone: 1
2013-05-14 10:14:31,681 DEBUG [cloud.deploy.FirstFitPlanner] 
(Job-Executor-22:job-20) Cluster: 1 has HyperVisorType that does not match the 
VM, skipping this cluster
2013-05-14 10:14:31,682 DEBUG [cloud.deploy.FirstFitPlanner] 
(Job-Executor-22:job-20) Could not find suitable Deployment Destination for 
this VM under any clusters, returning.
2013-05-14 10:14:31,684 DEBUG [cloud.vm.UserVmManagerImpl] 
(Job-Executor-22:job-20) Destroying vm VM[User|test-iso-1] as it failed to 
create on Host with Id:null
2013-05-14 10:14:31,703 DEBUG [cloud.capacity.CapacityManagerImpl] 
(Job-Executor-22:job-20) VM state transitted from :Stopped to Error with event: 
OperationFailedToErrorvm's original host id: null new host id: null host id 
before state transition: null
2013-05-14 10:14:31,712 WARN  [apache.cloudstack.alerts] 
(Job-Executor-22:job-20)  alertType:: 8 // dataCenterId:: 1 // podId:: null // 
clusterId:: null // message:: Failed to deploy Vm with Id: 6, on Host with Id: 
null
2013-05-14 10:14:31,752 INFO  [user.vm.DeployVMCmd] (Job-Executor-22:job-20) 
com.cloud.exception.InsufficientServerCapacityException: Unable to create a 
deployment for VM[User|test-iso-1]Scope=interface com.cloud.dc.DataCenter; id=1
2013-05-14 10:14:31,753 INFO  [user.vm.DeployVMCmd] (Job-Executor-22:job-20) 
Unable to create a deployment for VM[User|test-iso-1]
com.cloud.exception.InsufficientServerCapacityException: Unable to create a 
deployment for VM[User|test-iso-1]Scope=interface com.cloud.dc.DataCenter; id=1
        at 
org.apache.cloudstack.engine.cloud.entity.api.VMEntityManagerImpl.reserveVirtualMachine(VMEntityManagerImpl.java:197)
        at 
org.apache.cloudstack.engine.cloud.entity.api.VirtualMachineEntityImpl.reserve(VirtualMachineEntityImpl.java:198)
        at 
com.cloud.vm.UserVmManagerImpl.startVirtualMachine(UserVmManagerImpl.java:3062)
        at 
com.cloud.vm.UserVmManagerImpl.startVirtualMachine(UserVmManagerImpl.java:2673)
        at 
com.cloud.vm.UserVmManagerImpl.startVirtualMachine(UserVmManagerImpl.java:2659)
        at 
com.cloud.utils.component.ComponentInstantiationPostProcessor$InterceptorDispatcher.intercept(ComponentInstantiationPostProcessor.java:125)
        at 
org.apache.cloudstack.api.command.user.vm.DeployVMCmd.execute(DeployVMCmd.java:413)
        at com.cloud.api.ApiDispatcher.dispatch(ApiDispatcher.java:155)
        at 
com.cloud.async.AsyncJobManagerImpl$1.run(AsyncJobManagerImpl.java:437)
        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)
2013-05-14 10:14:31,753 DEBUG [cloud.async.AsyncJobManagerImpl] 
(Job-Executor-22:job-20) Complete async job-20, jobStatus: 2, resultCode: 530, 
result: Error Code: 533 Error text: Unable to create a deployment for 
VM[User|test-iso-1]


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to