Ask Your Question

Decreasing instance disk size

asked 2014-02-07 02:42:12 -0500

Y Sertdemir gravatar image


I am trying new havana version on my test system (on Ubuntu 12.04 LTS). I tried to resize a VM (Ubuntu 12.04 image), resizing to bigger flavor has no problem. When I try to resize instance to smaller flavor, root disk size remains same on instance but in openstack it shows the flavor size. I know that root disk size cannot be decreased on OS side, but Openstack should be aware of it and should show the old disk size.

Is there a workaround about this problem? For example, I want my users not be able to resize the instance to smaller one. Another workaround can be fixing the disk size to same for all flavors, but users will want to use the bigger root disks for windows machines.

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted

answered 2014-02-07 16:05:13 -0500

updated 2014-02-10 15:27:23 -0500

I saw the same behavior when shrinking a VM, and when I chatted with one of our lead developers he reviewed the code and said that is expected behavior. The question I had from my customer was if my file system was full (100%) and I did the re-size downward what happens to my data ? So in this case this is what was wanted by my customer. I also found this link its almost a year old but might be helpful.

When a resize request is issued, the current running state of the VM is saved and paused. The definition of the VM is then regenerated using the information for the new flavor. The CPU and RAM will always be changed. A check is done on the disk size. If the size of the disk in the new flavor is greater then the size in the old flavor the disk is resized. If the new flavor's disk is smaller, the disk isn't resized and remains the size of the original flavor. The API and dashboard will report the new size based upon the new flavor but the actual disk will remain the original larger size.

I would agree with you and not let them do or report the outcome of the re-size.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower


Asked: 2014-02-07 02:42:12 -0500

Seen: 2,400 times

Last updated: Feb 10 '14