Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
self.iproute2.link_add_veth(ifaceobj.name, peer_name)
elif link_type:
- self.netlink.link_add(ifname=ifaceobj.name, kind=link_type)
+ self.iproute2.link_add(ifaceobj.name, link_type)
def _down(self, ifaceobj):
if not ifaceobj.get_attr_value_first('link-type'):
###
+ def link_add(self, ifname, link_type):
+ utils.exec_command(
+ "%s link add %s type %s"
+ % (utils.ip_cmd, ifname, link_type)
+ )
+
+ ###
+
def link_add_macvlan(self, ifname, macvlan_ifname, macvlan_mode):
utils.exec_command(
"%s link add link %s name %s type macvlan mode %s"