resize disk down
Can Openstack rezise instances down?
First time here? Check out the FAQ!
Here's a blueprint discussing this:
https://blueprints.launchpad.net/nova...
The most relevant part:
Resize to a smaller disk can never work if the user already has more data than the new flavor allows - so for consistency any resize to a smaller flavour should be treated as an error.
The question is... will it let you do it via the API -- Maybe, but it should give you an error if it fails. This also may depend on the Hypervisor type and specific configuration options in nova.conf.
More helpful information:
So it resizes it down based on the flavor, but then the disk just stays the same. Is this the outcome you are seeing?
libvirt: logs it cannot resize to smaller and just keeps the larger disk
xen: tries to copy contents to a smaller disk, fails if too large
hyperv: always errors out if new disk size is smaller
powervm: silently keeps the larger disk
vmware: (couldn't find where migration code handled resize)
Makes sense. You need to edit a few settings in your .conf to allow same host migrations, otherwise it's trying to migrate to other hosts. If you aren't using distributed storage then this fails due to an SSH session opening. Check your error logs for nova on the compute node the instance is on.
Not too telling.
2014-06-25 17:20:28.067 27632 WARNING nova.compute.resource_tracker [-] [instance: e4798c6e-bf95-4b73-b013-0f351ecb3c36] Instance not resizing, skipping mig$
2014-06-25 17:20:57.158 27632 ERROR oslo.messaging.rpc.dispatcher [-] Exception during message handling: Resize error: Unable to resize disk down.
2014-06-25 17:20:57.158 27632 TRACE oslo.messaging.rpc.dispatcher Traceback (most recent call last):
2014-06-25 17:20:57.158 27632 TRACE oslo.messaging.rpc.dispatcher File "/usr/lib/python2.7/dist-packages/oslo/messaging/rpc/dispatcher.py", line 133, in _$
2014-06-25 17:20:57.158 27632 TRACE oslo.messaging.rpc.dispatcher incoming.message))
2014-06-25 17:20:57.158 27632 TRACE oslo.messaging.rpc.dispatcher File "/usr/lib/python2.7/dist-packages/oslo/messaging/rpc/dispatcher.py", line 176, in _$
2014-06-25 17:20:57.158 27632 TRACE oslo.messaging.rpc.dispatcher return self._do_dispatch(endpoint, method, ctxt, args)
2014-06-25 17:20:57.158 27632 TRACE oslo.messaging ...
(more)Your setup will not let you resize down then. Is there a reason you are wanting to resize down? Even with KVM if it went through successfully the disk size stays the same. If you want to actually change the hardware requirements you could look at making flavors that match the disk size but have different vcpu/memory.
Returning exception Resize error: Unable to resize disk down
Asked: 2014-06-25 13:34:15 -0500
Seen: 2,368 times
Last updated: Jun 25 '14