[ 
https://issues.apache.org/jira/browse/CLOUDSTACK-3877?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13721627#comment-13721627
 ] 

Rajesh Battala commented on CLOUDSTACK-3877:
--------------------------------------------

this issue is with the way we extract the hypevisor type from the sql 


mysql>  SELECT s.hypervisor, c.hypervisor_type from volumes v, storage_pool s, 
cluster c where v.pool_id = s.id and s.cluster_id = c.id and v.id = 21;
+------------+-----------------+
| hypervisor | hypervisor_type |
+------------+-----------------+
| NULL       | KVM             |
+------------+-----------------+



first column value will be not null if the storage pool is Zone wide else it 
will be NULL. 
but in the code always first column is considering to figure out the hypervisor 
type which causing the hpervisor type to be NONE and hence failing to resize 
the volume
                
> Unable to Resize Volume (kvm, vmware)
> -------------------------------------
>
>                 Key: CLOUDSTACK-3877
>                 URL: https://issues.apache.org/jira/browse/CLOUDSTACK-3877
>             Project: CloudStack
>          Issue Type: Bug
>      Security Level: Public(Anyone can view this level - this is the 
> default.) 
>          Components: Management Server, Storage Controller
>    Affects Versions: 4.1.1, 4.2.0
>         Environment: kvm, 4.2 code.
> instances running on Kvm. and volumes attached and present in cluster scope 
> primary storage
>            Reporter: Rajesh Battala
>            Priority: Blocker
>             Fix For: 4.1.1, 4.2.0
>
>
> ERROR [cloud.async.AsyncJobManagerImpl] (Job-Executor-8:job-40 = [ 
> 89b9f53d-abaa-47fe-91ba-13795b647a2b ]) Unexpected exception while executing 
> org.apache.cloudstack.api.command.user.volume.ResizeVolumeCmd
> com.cloud.exception.InvalidParameterValueException: Can't resize a volume 
> that has never been attached, not sure which hypervisor type. Recreate volume 
> to resize.
>         at 
> com.cloud.storage.VolumeManagerImpl.resizeVolume(VolumeManagerImpl.java:1108)
>         at 
> com.cloud.utils.component.ComponentInstantiationPostProcessor$InterceptorDispatcher.intercept(ComponentInstantiationPostProcessor.java:125)
>         at 
> com.cloud.storage.VolumeManagerImpl.resizeVolume(VolumeManagerImpl.java:185)
>         at 
> org.apache.cloudstack.api.command.user.volume.ResizeVolumeCmd.execute(ResizeVolumeCmd.java:137)
>         at com.cloud.api.ApiDispatcher.dispatch(ApiDispatcher.java:158)
>         at 
> com.cloud.async.AsyncJobManagerImpl$1.run(AsyncJobManagerImpl.java:531)
>         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)

--
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