https://github.com/midokura/incubator-cloudstack/tree/vif_driver_change
(Non-committer workflow, i.e. develop on external, pubic fork and submit patches)
Allow specification of different VIF drivers per traffic type in KVM.
This change allows the user to override the VIF Driver for specific traffic types using the agent config file (agent.properties).
The MidoNet plugin intends to handle Guest traffic for Guest and System VMs, and Public traffic for System VMs (Public traffic).
However, we wish to let Management / Control traffic be handled by the underlying physical network using the default BridgeVifDriver.
Currently, this is not possible without duplicating BridgeVifDriver code into the MidonetVifDriver, as LibVirtComputingResource assumes there is only one VIF driver.
Date |
Revision |
Author |
Description of the change |
---|---|---|---|
2/18/2013 |
0.1 |
Dave Cahill |
Initial Draft |
Term |
Definition |
---|---|
CS |
CloudStack |
This change targets the KVM hypervisor.
Currently, in agent.properties, the following configuration parameter exists:
libvirt.vif.driver
If this setting is not specified, the default VIF driver is com.cloud.hypervisor.kvm.resource.BridgeVifDriver.
LibVirtComputingResource uses the specified VIF driver for plugging all NICs, regardless of traffic type.
Allow users to set configuration options of the form below in agent.properties:
libvirt.vif.driver.TRAFFICTYPE
For example:
libvirt.vif.driver.Guest=com.cloud.network.resource.MidoNetVifDriver
When plugging NICs of a certain traffic type, LibVirtComputingResource will check if a specific VIF driver has been set for that traffic type, and if not, fall back to the default VIF driver.
Basic use case:
Using standard BridgeVifDriver. No changes required to workflow, configuration etc. Works as before.
Network plugin use case:
Using MidoNet plugin, want MidoNet to handle Guest and Public traffic only.
In agent.properties, set the following:
libvirt.vif.driver.Guest=com.cloud.network.resource.MidoNetVifDriver
libvirt.vif.driver.Public=com.cloud.network.resource.MidoNetVifDriver
This step would be part of the compute node deployment process (e.g. set in Chef scripts) when using the MidoNet plugin.
Before declaring the feature complete, the following regression tests should be verified in order to ensure backwards compatibility:
Using a default network offering using Virtual Router:
As mentioned above, after this change users can set config options of this type in agent.properties in KVM:
libvirt.vif.driver.TRAFFICTYPE
For example:
libvirt.vif.driver.Guest=com.cloud.network.resource.MidoNetVifDriver
None.
No change.
None.