Skip to content

Commit c2e2f6c

Browse files
author
Marcus Sorensen
committed
relax KVM agent setup to allow non-bridge traffic labels
(guest bridges are created on physical device, no need for bridge traffic label)
1 parent 918bc74 commit c2e2f6c

2 files changed

Lines changed: 4 additions & 3 deletions

File tree

plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtComputingResource.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1055,7 +1055,7 @@ private String matchPifFileInDirectory(String bridgeName){
10551055
String fname = interfaces[i].getName();
10561056
s_logger.debug("matchPifFileInDirectory: file name '"+fname+"'");
10571057
if (fname.startsWith("eth") || fname.startsWith("bond")
1058-
|| fname.startsWith("vlan") || fname.startsWith("em")
1058+
|| fname.startsWith("vlan") || fname.startsWith("vxlan") || fname.startsWith("em")
10591059
|| fname.matches("^p\\d+p\\d+.*")) {
10601060
return fname;
10611061
}

python/lib/cloudutils/serviceConfig.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -96,8 +96,9 @@ def isPreConfiged(self):
9696
return False
9797
if self.syscfg.env.bridgeType == "openvswitch" and not self.netcfg.isOvsBridge(br):
9898
raise CloudInternalException("%s is not an openvswitch bridge" % br)
99-
if self.syscfg.env.bridgeType == "native" and not self.netcfg.isBridge(br):
100-
raise CloudInternalException("%s is not a bridge" % br)
99+
if self.syscfg.env.bridgeType == "native" and not self.netcfg.isBridge(br) and not self.netcfg.isNetworkDev(br):
100+
# traffic label doesn't have to be a bridge, we'll create bridges on it
101+
raise CloudInternalException("%s is not a bridge and not a net device" % br)
101102
preCfged = True
102103

103104
return preCfged

0 commit comments

Comments
 (0)