Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.

Bug 1241501

Summary: RFE: Allow resizing of instances by default in the Nova configuration
Product: Red Hat OpenStack Reporter: Yogev Rabl <yrabl>
Component: rhosp-directorAssignee: Hugh Brock <hbrock>
Status: CLOSED CURRENTRELEASE QA Contact: Yogev Rabl <yrabl>
Severity: high Docs Contact:
Priority: high    
Version: DirectorCC: alsilva, bnemec, jcoufal, mburns, mcornea, rhel-osp-director-maint
Target Milestone: ---Keywords: FutureFeature, Triaged
Target Release: 10.0 (Newton)   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-09-27 03:14:26 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 1221776, 1267598    
Bug Blocks:    

Description Yogev Rabl 2015-07-09 10:49:23 UTC
Description of problem:
The resizing of an instance requires the parameter allow_resize_to_same_host in the /etc/nova/nova.conf must be set to true. Currently, the parameter is commented out as: 
#allow_resize_to_same_host=false

Thus the resize action is not available. 

Version-Release number of selected component (if applicable):
openstack-tripleo-image-elements-0.9.6-5.el7ost.noarch
openstack-heat-templates-0-0.6.20150605git.el7ost.noarch
openstack-tripleo-heat-templates-0.8.6-23.el7ost.noarch
openstack-tripleo-0.0.7-0.1.1664e566.el7ost.noarch
openstack-tripleo-puppet-elements-0.0.1-3.el7ost.noarch

How reproducible:
100% 

Steps to Reproduce:
1. Launch an instance 
2. Resize the instance
3. Check the configuration in the nova.conf of the compute nodes
# sudo grep allow_resize_to_same_host /etc/nova/nova.conf

Actual results:
The resize action fails with the error:
ERROR (BadRequest): No valid host was found. No valid host found for resize (HTTP 400)

Expected results:
The resize of the instance should succeed 

Additional info:

Comment 3 Ben Nemec 2015-08-19 15:12:20 UTC
"The resizing of an instance requires the parameter allow_resize_to_same_host in the /etc/nova/nova.conf must be set to true."

Note that this is only true if you have exactly one compute node.  In any real deployment it is not going to be an issue.

Comment 4 Yogev Rabl 2015-08-20 08:23:21 UTC
Whenever I tried to resize an instance with no relation to the number of compute nodes I had I always had to change this parameter in order for the resize to work.

Comment 6 Ben Nemec 2015-08-21 16:57:48 UTC
Ah, that would be because of https://bugzilla.redhat.com/show_bug.cgi?id=1221776

Resizing requires the same inter-compute ssh access as migrate.

Comment 9 Mike Burns 2016-04-07 20:43:53 UTC
This bug did not make the OSP 8.0 release.  It is being deferred to OSP 10.

Comment 11 Alessandro Silva 2016-05-27 18:48:43 UTC
I have an "all in one" installation. The "allow_resize_to_same_host=true" option solved when scaling up instances, but if we decided scaling down, did not work.

Comment 12 Ben Nemec 2016-05-31 13:34:03 UTC
In my experience, scaling down usually fails due to the disk size in the new flavor being smaller than the previous one.  Since OpenStack can't resize the partition in the instance before changing the flavor it's not possible to scale down that way.  However, scaling down to a flavor with the same size disk but less cpu and memory should work fine.

Comment 13 Jaromir Coufal 2016-09-27 03:14:26 UTC
Scale up is supported. Scale down only manual.