Read more

Openstack: nova resize

Claus-Theodor Riegg
July 31, 2015Software engineer at makandra GmbH

To change RAM size, VDISK size or VCPU count of an openstack instance you have to use nova resize. You can't change for e.g. just the RAM size with a parameter, you have to assign a new/other flavor. If there is no suitable flavor for the new properties of the VM, create a new one.

Illustration book lover

Growing Rails Applications in Practice

Check out our e-book. Learn to structure large Ruby on Rails codebases with the tools you already know and love.

  • Introduce design conventions for controllers and user-facing models
  • Create a system for growth
  • Build applications to last
Read more Show archive.org snapshot

nova resize [--poll] <server> <flavor>

The resize could take a while, after it is finished, the VM boots up with the new specifications. SSH into the VM and check if everything is alright. If so -> use nova resize-confirm <server> to get rid of the old VM image and keep the new one. If you run into any trouble you can use nova-resize-revert <server> to drop the new VM image and use the old one.

Please mind the following:

  • openstack will shutdown the VM before the resize, so you have to acknowledge a downtime
  • be careful if you resize a vdisk to a smaller value, as there is the risk of losing data
  • as openstack recreates the image with qemu-img convert, a resize can take a long time (depending on the size of the disk)
Posted by Claus-Theodor Riegg to makandra dev (2015-07-31 10:33)