[openstack-dev] [nova][scheduling] Can VM placement consider the VM network traffic need?

Balazs Gibizer balazs.gibizer at ericsson.com
Fri Sep 1 09:16:14 UTC 2017


On Fri, Sep 1, 2017 at 10:42 AM, Rua, Philippe (Nokia - FI/Espoo) 
<philippe.rua at nokia.com> wrote:
> Will it be possible to include network bandwidth as a resource in 
> Nova scheduling, for VM placement decision?

I think it will.

> 
> 
> Context: in telecommunication applications, the network traffic is an 
> important dimension of resource usage. For example, it is often 
> important to distribute "bandwidth-greedy" VMs to different compute 
> nodes. There were some earlier discussions on this topic, but I could 
> not find a concrete outcome. [1][2][3]
> 
> After some reading, I wonder whether the Custom resource classes can 
> provide a generic mechanism? [4][5][6]
> Here is what I have in mind:
> - The VM need is specified in the flavor extra-specs, e.g. 
> resources:CUSTOM_BANDWIDTH=123.
> - The compute node total capacity is specified in host aggregate 
> metadata, e.g. CUSTOM_BANDWIDTH=999.

I'm not aware of any feature that considers aggregate metadata key as 
resource inventory. As far as I know you have to define new resource 
providers for your CUSTOM_BANDWIDTH resource via the placement API and 
you have to report the 999 as inventory on those resource providers 
also via placement API. Also don't forget to connect your resource 
provider to the existing compute resource providers via an aggregate 
(this is an aggregate in placement which is different from the host 
aggregate concept in nova). This review contains some test cases that 
can help you how to set things up 
https://review.openstack.org/#/c/497399
> 
> - Nova then takes care of the rest: scheduling where the free 
> capacity is sufficient, and performing simple resource usage 
> accounting (updating the compute node free network bandwidth capacity 
> as required).

With the above flavor extra spec as request and the above resource 
provider setup nova will do the rest of the resource accounting for the 
your custom resource. Except in case you hit one of the bugs we 
discovered in this area 
https://bugs.launchpad.net/nova/+bugs?field.tag=placement

> 
> 
> Is the outline above according to current plans?
> If not, what would be possible/needed in order to achieve the same 
> result, i.e. consider the VM network traffic need during VM placement?

You might want to keep an eye on the nested-resource-provider work 
planned for Queens as it will give you better options to model your 
resources: 
https://blueprints.launchpad.net/nova/+spec/nested-resource-providers

Cheers,
gibi

> 
> 
> BR,
> Philippe
> 
> [1] 
> https://blueprints.launchpad.net/nova/+spec/bandwidth-as-scheduler-metric
> [2] https://wiki.openstack.org/wiki/NetworkBandwidthEntitlement
> [3] 
> https://openstack.nimeyo.com/80515/openstack-scheduling-bandwidth-resources-nic_bw_kb-resource
> [4] https://docs.openstack.org/nova/latest/user/placement.html
> [5] 
> http://specs.openstack.org/openstack/nova-specs/priorities/pike-priorities.html#placement
> [6] https://review.openstack.org/#/c/473627/
> 
> __________________________________________________________________________
> OpenStack Development Mailing List (not for usage questions)
> Unsubscribe: 
> OpenStack-dev-request at lists.openstack.org?subject:unsubscribe
> http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev




More information about the OpenStack-dev mailing list