Repository navigation
Failed to attach volume to instance on VMware #9858
Copy link
Copy link
Closed
Milestone
Description
ISSUE TYPE
- Bug Report
COMPONENT NAME
Instance
CLOUDSTACK VERSION
4.19.1.1
CONFIGURATION
Set DatadiskController and RootdiskController for VM use same controller: pvscsi
Create and attach volume use same disk offering with instance
OS / ENVIRONMENT
Cloudstack version: 4.19.1.1
vSphere: 8.0.3
VMware Esxi: 8.0.2
SUMMARY
Failed to attach volume to instance
STEPS TO REPRODUCE
Click Create and Add Volume in instance
Select disk offering use for instance
Results: Failed to attach volume to instance
2024-10-28 13:52:23,284 ERROR [c.c.a.ApiAsyncJobDispatcher] (API-Job-Executor-4:ctx-715f606f job-6464) (logid:220769b8) Unexpected exception while executing org.apache.cloudstack.api.command.admin.volume.AttachVolumeCmdByAdmin
com.cloud.utils.exception.CloudRuntimeException: Failed to attach volume data to VM test-disk-vmware
at com.cloud.storage.VolumeApiServiceImpl.sendAttachVolumeCommand(VolumeApiServiceImpl.java:4598)
at com.cloud.storage.VolumeApiServiceImpl.orchestrateAttachVolumeToVM(VolumeApiServiceImpl.java:2489)
at com.cloud.storage.VolumeApiServiceImpl.orchestrateAttachVolumeToVM(VolumeApiServiceImpl.java:5017)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:566)
at com.cloud.vm.VmWorkJobHandlerProxy.handleVmWorkJob(VmWorkJobHandlerProxy.java:105)
at com.cloud.storage.VolumeApiServiceImpl.handleVmWorkJob(VolumeApiServiceImpl.java:5063)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:566)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:344)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:198)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163)
at org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:97)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:215)
at com.sun.proxy.$Proxy247.handleVmWorkJob(Unknown Source)
at com.cloud.vm.VmWorkJobDispatcher.runJob(VmWorkJobDispatcher.java:102)
at org.apache.cloudstack.framework.jobs.impl.AsyncJobManagerImpl$5.runInContext(AsyncJobManagerImpl.java:654)
at org.apache.cloudstack.managed.context.ManagedContextRunnable$1.run(ManagedContextRunnable.java:48)
at org.apache.cloudstack.managed.context.impl.DefaultManagedContext$1.call(DefaultManagedContext.java:55)
at org.apache.cloudstack.managed.context.impl.DefaultManagedContext.callWithContext(DefaultManagedContext.java:102)
at org.apache.cloudstack.managed.context.impl.DefaultManagedContext.runWithContext(DefaultManagedContext.java:52)
at org.apache.cloudstack.managed.context.ManagedContextRunnable.run(ManagedContextRunnable.java:45)
at org.apache.cloudstack.framework.jobs.impl.AsyncJobManagerImpl$5.run(AsyncJobManagerImpl.java:602)
at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.lang.Thread.run(Thread.java:829)
2024-10-28 13:52:23,290 DEBUG [o.a.c.f.j.i.AsyncJobManagerImpl] (API-Job-Executor-4:ctx-715f606f job-6464) (logid:220769b8) Complete async job-6464, jobStatus: FAILED, resultCode: 530, result: org.apache.cloudstack.api.response.ExceptionResponse/null/{"uuidList":[],"errorcode":"530","errortext":"Failed to attach volume data to VM test-disk-vmware"}
EXPECTED RESULTS
Volume create and attach to instance
ACTUAL RESULTS
Volume create success but not attach to instance
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels
Activity
DaanHoogland commentedon Oct 29, 2024
@leduyquy I tried bot main and latest 4.19 but cannot reproduce.
I created a vm with a root only
then went into the vvolumes tab of that VM and clicked "create and add volume"
all worked in both versions. Is there any other version you can check against?
Also I checked the stacktrace you provided against 4.19.1.1 and it doesn't match. Can you double check the version?
leduyquy commentedon Oct 29, 2024
Thank for @DaanHoogland for taking care of that issue.
Maybe the error is caused by version vsphere, I have downgrade version vsphere to 8.0.0 and it worked.