summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorahothan <ahothan@cisco.com>2018-12-08 12:22:22 -0800
committerahothan <ahothan@cisco.com>2018-12-08 12:22:22 -0800
commit40d716a6fca17fcbba066769b503f8aeeea400dc (patch)
treebd1aca28507e4d4f47c73bfceb686b45b9797d3f
parented1df5da8e6468ec7a0e25a853fe803bfc0af3f6 (diff)
NFVBENCH-119 cli option --vxlan not working
Change-Id: Ib1dbca96fc5c5108078c6de623127ca49c439a1d Signed-off-by: ahothan <ahothan@cisco.com>
-rw-r--r--nfvbench/nfvbench.py19
1 files changed, 9 insertions, 10 deletions
diff --git a/nfvbench/nfvbench.py b/nfvbench/nfvbench.py
index f06c593..cdb99c8 100644
--- a/nfvbench/nfvbench.py
+++ b/nfvbench/nfvbench.py
@@ -66,16 +66,6 @@ class NFVBench(object):
self.specs.set_openstack_spec(openstack_spec)
self.vni_ports = []
sys.stdout.flush()
- self.check_options()
-
- def check_options(self):
- if self.base_config.vxlan:
- if self.base_config.vlan_tagging:
- raise Exception(
- 'Inner VLAN tagging is not currently supported for VXLAN')
- vtep_vlan = self.base_config.traffic_generator.get('vtep_vlan')
- if vtep_vlan is None:
- LOG.warning('Warning: VXLAN mode enabled, but VTEP vlan is not defined')
def set_notifier(self, notifier):
self.notifier = notifier
@@ -223,6 +213,13 @@ class NFVBench(object):
raise Exception('Please provide existing path for storing results in JSON file. '
'Path used: {path}'.format(path=config.std_json_path))
+ # VxLAN sanity checks
+ if config.vxlan:
+ if config.vlan_tagging:
+ config.vlan_tagging = False
+ LOG.info('VxLAN: vlan_tagging forced to False '
+ '(inner VLAN tagging must be disabled)')
+
self.config_plugin.validate_config(config, self.specs.openstack)
@@ -544,6 +541,8 @@ def main():
if opts.hypervisor:
# can be any of 'comp1', 'nova:', 'nova:comp1'
config.compute_nodes = opts.hypervisor
+ if opts.vxlan:
+ config.vxlan = True
# port to port loopback (direct or through switch)
if opts.l2_loopback: