Introduction:

This document describes the multiple vlan range feature.
Presetntly in cloudstack we can only extend the vlan range but cannot add multiple non contiguous vlan ranges. This feature provides this flexibility to add multiple vlan ranges.

Use case:

The admin may want to add a new vlan range once the existing vlan range is exhausted or the admin may want to add multiple vlan ranges based on the way he provisioned vlans.

Design description:

Admin can update the vlan range after creation or can add multiple non contiguous vlan ranges while creating a zone. This can be done by changing the UpdatephysicalNetwork api. It allows only extending of the vlan. we plan to extend the api to update the vlan with multiple ip ranges.

API

API Name

API parameters

API response

Available only for root admin

UpdatePhysicalNetwork

vlan, replacevlanrange

returns the updated vlan ranges

yes

vlan parameter will add a new vlan range to the existing vlan range. if the new vlan range overlaps the existing vlan range it will extend that vlan.
replacevlanrange parameter will replace the mentioned vlan with the new vlan. The replacevlanrange and vlan parameters should be used together. The valn parameter gives the new vlan range and the replacevlanrange gives the vlan range to be replaced. If the vlan range we are trying to replace is in use, the operation will not succeed.

Db changes.

No data base changes are required.