Is shrinking an RBD datadisk volume supported in ACS 4.15.0.0? When I try to shrink the volume (volume has no data on it and is unattached) I get an error:
2021-08-10 04:05:03,150 DEBUG [c.c.a.t.Request] (API-Job-Executor-19:ctx-24b7cda8 job-771 ctx-c40ce838) (logid:ef1cc616) Seq 17-2639953806569271643: Sending { Cmd , MgmtId: 90520733511963, via: 17(bllcloudcmp01), Ver: v1, Flags: 100011, [{"com.cloud.agent.api.storage.ResizeVolumeCommand":{"path":"649f1b12-fd51-4171-bf70-b22a3cb74c57","pool":{"id":"10","uuid":"35850adc-d711-306f-b111-9c90205274b1","host":"bllcloudceph01-storage.harmonywave.cloud","path":"cloudstack","userInfo":"cloudstack:AQDURgdhqpXiOBAAuDq6_LET116OIBZU11pg0Q==","port":"0","type":"RBD"},"currentSize":"107374182400","newSize":"(20.00 GB) 21474836480","shrinkOk":"true","vmInstance":"none","managed":"false","wait":"0"}}] } 2021-08-10 04:05:03,443 DEBUG [c.c.a.t.Request] (AgentManager-Handler-12:null) (logid:) Seq 17-2639953806569271643: Processing: { Ans: , MgmtId: 90520733511963, via: 17, Ver: v1, Flags: 10, [{"com.cloud.agent.api.storage.ResizeVolumeAnswer":{"newSize":"(0 bytes) 0","result":"false","details":"org.libvirt.LibvirtException: invalid argument: can't shrink capacity below existing allocation","wait":"0"}}] } 2021-08-10 04:05:03,443 DEBUG [c.c.a.t.Request] (API-Job-Executor-19:ctx-24b7cda8 job-771 ctx-c40ce838) (logid:ef1cc616) Seq 17-2639953806569271643: Received: { Ans: , MgmtId: 90520733511963, via: 17(bllcloudcmp01), Ver: v1, Flags: 10, { ResizeVolumeAnswer } } 2021-08-10 04:05:03,507 WARN [o.a.c.s.d.ObjectInDataStoreManagerImpl] (API-Job-Executor-19:ctx-24b7cda8 job-771 ctx-c40ce838) (logid:ef1cc616) Unsupported data object (VOLUME, org.apache.cloudstack.storage.datastore.PrimaryDataStoreImpl@577a814a), no need to delete from object in store ref table 2021-08-10 04:05:03,510 WARN [c.c.s.VolumeApiServiceImpl] (API-Job-Executor-19:ctx-24b7cda8 job-771 ctx-c40ce838) (logid:ef1cc616) Failed to resize the volume Vol[75|vm=null|DATADISK] 2021-08-10 04:05:03,581 ERROR [c.c.a.ApiAsyncJobDispatcher] (API-Job-Executor-19:ctx-24b7cda8 job-771) (logid:ef1cc616) Unexpected exception while executing org.apache.cloudstack.api.command.admin.volume.ResizeVolumeCmdByAdmin com.cloud.utils.exception.CloudRuntimeException: Exception caught during resize volume operation of volume UUID: 649f1b12-fd51-4171-bf70-b22a3cb74c57 at com.cloud.storage.VolumeApiServiceImpl.orchestrateResizeVolume(VolumeApiServiceImpl.java:1288) at com.cloud.storage.VolumeApiServiceImpl.resizeVolume(VolumeApiServiceImpl.java:1147) at com.cloud.storage.VolumeApiServiceImpl.resizeVolume(VolumeApiServiceImpl.java:191) 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.apache.cloudstack.network.contrail.management.EventUtils$EventInterceptor.invoke(EventUtils.java:107) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:175) at com.cloud.event.ActionEventInterceptor.invoke(ActionEventInterceptor.java:51) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:175) at org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:95) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186) at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:212) at com.sun.proxy.$Proxy215.resizeVolume(Unknown Source) at org.apache.cloudstack.api.command.user.volume.ResizeVolumeCmd.execute(ResizeVolumeCmd.java:191) at com.cloud.api.ApiDispatcher.dispatch(ApiDispatcher.java:156) at com.cloud.api.ApiAsyncJobDispatcher.runJob(ApiAsyncJobDispatcher.java:108) at org.apache.cloudstack.framework.jobs.impl.AsyncJobManagerImpl$5.runInContext(AsyncJobManagerImpl.java:620) 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:568) 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) Caused by: com.cloud.utils.exception.CloudRuntimeException: org.libvirt.LibvirtException: invalid argument: can't shrink capacity below existing allocation at com.cloud.storage.VolumeApiServiceImpl.orchestrateResizeVolume(VolumeApiServiceImpl.java:1248) at com.cloud.storage.VolumeApiServiceImpl.resizeVolume(VolumeApiServiceImpl.java:1147) at com.cloud.storage.VolumeApiServiceImpl.resizeVolume(VolumeApiServiceImpl.java:191) ... 30 more I'm assuming this operation just isn't supported by libvirt or Ceph, but would like to know for sure. -- Thanks, Joshua Schaeffer