You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cloudstack.apache.org by "manasaveloori (JIRA)" <ji...@apache.org> on 2013/12/02 11:44:36 UTC

[jira] [Created] (CLOUDSTACK-5329) MigrateVMCmd on stopped VM is failing with NPE when trying to migrate to zone-wide-primary storage.

manasaveloori created CLOUDSTACK-5329:
-----------------------------------------

             Summary: MigrateVMCmd on stopped VM is failing with NPE when trying to migrate to zone-wide-primary storage.
                 Key: CLOUDSTACK-5329
                 URL: https://issues.apache.org/jira/browse/CLOUDSTACK-5329
             Project: CloudStack
          Issue Type: Bug
      Security Level: Public (Anyone can view this level - this is the default.)
          Components: Storage Controller
    Affects Versions: 4.3.0
            Reporter: manasaveloori
            Priority: Critical
             Fix For: 4.3.0
         Attachments: management-server.rar

Steps:
1.	Have a CS with multiple zone wide primary storage using KVM host.
2.	Deploy a VM and stop it.
3.	Now goto  Migrate VM.Drop down lists the available primary storage to migrate.
4.	Now migrate the VM to another zone wide primary storage.

Observation:
Observed the following NPE:

2013-12-02 21:16:04,537 DEBUG [o.a.c.f.j.i.AsyncJobManagerImpl] (Job-Executor-49:ctx-63bbd88b) Executing AsyncJobVO {id:91, userId: 2, accountId: 2, instanceType: None, instanceId: null, cmd: org.apache.cloudstack.api.command.admin.vm.MigrateVMCmd, cmdInfo: {"response":"json","sessionkey":"bETJCcI/wg7sd2gWxD7zzG5wotQ\u003d","virtualmachineid":"d22ce820-339c-4c80-a16b-dd21bd7a8804","cmdEventType":"VM.MIGRATE","ctxUserId":"2","storageid":"b01ec063-b9c5-3685-b5ea-c816554f1ffe","httpmethod":"GET","_":"1385979761075","ctxAccountId":"2","ctxStartEventId":"293"}, cmdVersion: 0, status: IN_PROGRESS, processStatus: 0, resultCode: 0, result: null, initMsid: 6758231703598, completeMsid: null, lastUpdated: null, lastPolled: null, created: null}
2013-12-02 21:16:04,562 ERROR [c.c.a.ApiAsyncJobDispatcher] (Job-Executor-49:ctx-63bbd88b) Unexpected exception while executing org.apache.cloudstack.api.command.admin.vm.MigrateVMCmd
java.lang.NullPointerException
        at com.cloud.vm.UserVmManagerImpl.vmStorageMigration(UserVmManagerImpl.java:3954)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:601)
        at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:317)
        at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:183)
        at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:150)
        at org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:91)
        at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
        at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
        at $Proxy169.vmStorageMigration(Unknown Source)
        at org.apache.cloudstack.api.command.admin.vm.MigrateVMCmd.execute(MigrateVMCmd.java:150)
        at com.cloud.api.ApiDispatcher.dispatch(ApiDispatcher.java:161)
        at com.cloud.api.ApiAsyncJobDispatcher.runJobInContext(ApiAsyncJobDispatcher.java:109)
        at com.cloud.api.ApiAsyncJobDispatcher$1.run(ApiAsyncJobDispatcher.java:66)
        at org.apache.cloudstack.managed.context.impl.DefaultManagedContext$1.call(DefaultManagedContext.java:56)
        at org.apache.cloudstack.managed.context.impl.DefaultManagedContext.callWithContext(DefaultManagedContext.java:103)
        at org.apache.cloudstack.managed.context.impl.DefaultManagedContext.runWithContext(DefaultManagedContext.java:53)
        at com.cloud.api.ApiAsyncJobDispatcher.runJob(ApiAsyncJobDispatcher.java:63)
        at org.apache.cloudstack.framework.jobs.impl.AsyncJobManagerImpl$5.runInContext(AsyncJobManagerImpl.java:520)
        at org.apache.cloudstack.managed.context.ManagedContextRunnable$1.run(ManagedContextRunnable.java:49)
        at org.apache.cloudstack.managed.context.impl.DefaultManagedContext$1.call(DefaultManagedContext.java:56)
        at org.apache.cloudstack.managed.context.impl.DefaultManagedContext.callWithContext(DefaultManagedContext.java:103)
        at org.apache.cloudstack.managed.context.impl.DefaultManagedContext.runWithContext(DefaultManagedContext.java:53)
        at org.apache.cloudstack.managed.context.ManagedContextRunnable.run(ManagedContextRunnable.java:46)
        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:722)
2013-12-02 21:16:04,566 DEBUG [o.a.c.f.j.i.AsyncJobManagerImpl] (Job-Executor-49:ctx-63bbd88b) Complete async job-91, jobStatus: FAILED, resultCode: 530, result: org.apache.cloudstack.api.response.ExceptionResponse/null/{"uuidList":[],"errorcode":530}
2013-12-02 21:16:04,584 DEBUG [o.a.c.f.j.i.AsyncJobManagerImpl] (Job-Executor-49:ctx-63bbd88b) Done executing org.apache.cloudstack.api.command.admin.vm.MigrateVMCmd for job-91
2013-12-02 21:16:04,592 INFO  [o.a.c.f.j.i.AsyncJobMonitor] (Job-Executor-49:ctx-63bbd88b) Remove job-91 from job monitoring
2013-12-02 21:16:05,154 DEBUG [c.c.a.m.AgentManagerImpl] (AgentManager-Handler-6:null) SeqA 2-2579: Processing Seq 2-2579:  { Cmd , MgmtId: -1, via: 2, Ver: v1, Flags: 11, [{"com.cloud.agent.api.ConsoleProxyLoadReportCommand":{"_proxyVmId":2,"_loadInfo":"{\n  \"connections\": []\n}","wait":0}}]


Attaching the Mslogs



--
This message was sent by Atlassian JIRA
(v6.1#6144)