[ 
https://issues.apache.org/jira/browse/CLOUDSTACK-5556?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Kishan Kavala updated CLOUDSTACK-5556:
--------------------------------------

    Assignee: Rayees Namathponnan  (was: Kishan Kavala)

> [Automation] Failed to re-attach the volume in KVM
> --------------------------------------------------
>
>                 Key: CLOUDSTACK-5556
>                 URL: https://issues.apache.org/jira/browse/CLOUDSTACK-5556
>             Project: CloudStack
>          Issue Type: Bug
>      Security Level: Public(Anyone can view this level - this is the 
> default.) 
>          Components: Volumes
>    Affects Versions: 4.3.0
>         Environment: KVM (RHEL 6.3)
> Branch 4.3
>            Reporter: Rayees Namathponnan
>            Assignee: Rayees Namathponnan
>            Priority: Critical
>             Fix For: 4.3.0
>
>
> Steps to reproduce 
> Step 1 : Create advanced zone in KVM
> Step 2 : Deploy a VM
> Step 3 : Add new Volume 
> Step 4 : Attach the volume to vm
> Step 5 : Remove volume from the vm
> Step 6 : attach the same volume again 
> Result 
> Failed to attach the volume second time, with error "Failed to attach volume: 
> vol1 to VM: RYZ1; org.libvirt.LibvirtException: internal error unable to 
> execute QEMU command '__com.redhat_drive_add': Duplicate ID 
> 'drive-virtio-disk1' for drive"
> Observed below error in MS log
> 2013-12-18 22:20:49,276 DEBUG [c.c.a.t.Request] (Job-Executor-51:ctx-98ec33fc 
> ctx-5303d6ac) Seq 1-1588070511: Sending  { Cmd , MgmtId: 29066118877352, via: 
> 1(Rack2Host11.lab.vmops.com), Ver: v1, Flags: 100011, 
> [{"org.apache.cloudstack.storage.command.AttachCommand":{"disk":{"data":{"org.apache.cloudstack.storage.to.VolumeObjectTO":{"uuid":"afcc7fa1-dd56-49cb-9246-2806d20dbcc4","volumeType":"DATADISK","dataStore":{"org.apache.cloudstack.storage.to.PrimaryDataStoreTO":{"uuid":"fff90cb5-06dd-33b3-8815-d78c08ca01d9","id":1,"poolType":"NetworkFilesystem","host":"10.223.110.232","path":"/export/home/rayees/SC_QA_AUTO4/primary","port":2049,"url":"NetworkFilesystem://10.223.110.232//export/home/rayees/SC_QA_AUTO4/primary/?ROLE=Primary&STOREUUID=fff90cb5-06dd-33b3-8815-d78c08ca01d9"}},"name":"vol1","size":5368709120,"path":"afcc7fa1-dd56-49cb-9246-2806d20dbcc4","volumeId":484,"accountId":2,"format":"QCOW2","id":484,"hypervisorType":"KVM"}},"diskSeq":1,"path":"afcc7fa1-dd56-49cb-9246-2806d20dbcc4","type":"DATADISK","_details":{"managed":"false","storagePort":"2049","storageHost":"10.223.110.232","volumeSize":"5368709120"}},"vmName":"i-2-433-QA","wait":0}}]
>  }
> 2013-12-18 22:20:49,568 DEBUG [c.c.a.t.Request] (AgentManager-Handler-4:null) 
> Seq 1-1588070511: Processing:  { Ans: , MgmtId: 29066118877352, via: 1, Ver: 
> v1, Flags: 10, 
> [{"org.apache.cloudstack.storage.command.AttachAnswer":{"result":false,"details":"org.libvirt.LibvirtException:
>  internal error unable to execute QEMU command '__com.redhat_drive_add': 
> Duplicate ID 'drive-virtio-disk1' for drive","wait":0}}] }
> 2013-12-18 22:20:49,568 DEBUG [c.c.a.t.Request] (Job-Executor-51:ctx-98ec33fc 
> ctx-5303d6ac) Seq 1-1588070511: Received:  { Ans: , MgmtId: 29066118877352, 
> via: 1, Ver: v1, Flags: 10, { AttachAnswer } }
> 2013-12-18 22:20:49,568 ERROR [c.c.a.ApiAsyncJobDispatcher] 
> (Job-Executor-51:ctx-98ec33fc) Unexpected exception while executing 
> org.apache.cloudstack.api.command.user.volume.AttachVolumeCmd
> com.cloud.utils.exception.CloudRuntimeException: Failed to attach volume: 
> vol1 to VM: RYZ1; org.libvirt.LibvirtException: internal error unable to 
> execute QEMU command '__com.redhat_drive_add': Duplicate ID 
> 'drive-virtio-disk1' for drive
>       at 
> com.cloud.storage.VolumeApiServiceImpl.sendAttachVolumeCommand(VolumeApiServiceImpl.java:1879)
>       at 
> com.cloud.storage.VolumeApiServiceImpl.attachVolumeToVM(VolumeApiServiceImpl.java:1264)
>       at 
> com.cloud.storage.VolumeApiServiceImpl.orchestrateAttachVolumeToVM(VolumeApiServiceImpl.java:1088)
>       at 
> com.cloud.storage.VolumeApiServiceImpl.attachVolumeToVM(VolumeApiServiceImpl.java:1063)
>       at sun.reflect.GeneratedMethodAccessor610.invoke(Unknown Source)
>       at 
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>       at java.lang.reflect.Method.invoke(Method.java:616)
>       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 $Proxy193.attachVolumeToVM(Unknown Source)
>       at 
> org.apache.cloudstack.api.command.user.volume.AttachVolumeCmd.execute(AttachVolumeCmd.java:123)
>       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:521)
>       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:679)
> 2013-12-18 22:20:49,569 DEBUG [o.a.c.f.j.i.AsyncJobManagerImpl] 
> (Job-Executor-51:ctx-98ec33fc) Complete async job-1726, jobStatus: FAILED, 
> resultCode: 530, result: 
> org.apache.cloudstack.api.response.ExceptionResponse/null/{"uuidList":[],"errorcode":530,"errortext":"Failed
>  to attach volume: vol1 to VM: RYZ1; org.libvirt.LibvirtException: internal 
> error unable to execute QEMU command \u0027__com.redhat_drive_add\u0027: 
> Duplicate ID \u0027drive-virtio-disk1\u0027 for drive"}
> 2013-12-18 22:20:49,575 DEBUG [o.a.c.f.j.i.AsyncJobManagerImpl] 
> (Job-Executor-51:ctx-98ec33fc) Done executing 
> org.apache.cloudstack.api.command.user.volume.AttachVolumeCmd for job-1726
> 2013-12-18 22:20:49,580 INFO  [o.a.c.f.j.i.AsyncJobMonitor] 
> (Job-Executor-51:ctx-98ec33fc) Remove job-1726 from job monitoring
> 2013-12-18 22:20:50,168 DEBUG [c.c.a.m.AgentManagerImpl] 
> (AgentManager-Handler-9:null) SeqA 9-1830: Processing Seq 9-1830:  { Cmd , 
> MgmtId: -1, via: 9, Ver: v1, Flags: 11, 
> [{"com.cloud.agent.api.ConsoleProxyLoadReportCommand":{"_proxyVmId":77,"_loadInfo":"{\n
>   \"connections\": []\n}","wait":0}}] }
> 2013-12-18 22:20:50,172 DEBUG [c.c.a.m.AgentManagerImpl] 
> (AgentManager-Handler-9:null) SeqA 9-1830: Sending Seq 9-1830:  { Ans: , 
> MgmtId: 29066118877352, via: 9, Ver: v1, Flags: 100010, 
> [{"com.cloud.agent.api.AgentControlAnswer":{"result":true,"wait":0}}] }
> 2013-12-18 22:20:50,499 WARN  [o.a.c.f.j.i.AsyncJobMonitor] 
> (Timer-1:ctx-05dbd90f) Task (job-1714) has been pending for 114 seconds
> 2013-12-18 22:20:50,499 WARN  [o.a.c.f.j.i.AsyncJobMonitor] 
> (Timer-1:ctx-05dbd90f) Task (job-1715) has been pending for 98 seconds



--
This message was sent by Atlassian JIRA
(v6.1.5#6160)

Reply via email to