From 834ceea55d29227d8b05f3d3d30d321bcbcceaeb Mon Sep 17 00:00:00 2001 From: Blake Harnden <32446120+bharnden@users.noreply.github.com> Date: Thu, 9 Jan 2020 13:52:36 -0800 Subject: [PATCH] updates to sdn ovs service to use ip instead of deprecated ifconfig --- daemon/core/services/sdn.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/daemon/core/services/sdn.py b/daemon/core/services/sdn.py index 413ea8d6..0aa824f9 100644 --- a/daemon/core/services/sdn.py +++ b/daemon/core/services/sdn.py @@ -42,7 +42,7 @@ class OvsService(SdnService): cfg += "# auto-generated by OvsService (OvsService.py)\n" cfg += "/etc/init.d/openvswitch-switch start < /dev/null\n" cfg += "ovs-vsctl add-br ovsbr0 -- set Bridge ovsbr0 fail-mode=secure\n" - cfg += "ifconfig ovsbr0 up\n" + cfg += "ip link set dev ovsbr0 up\n" for ifc in node.netifs(): if hasattr(ifc, "control") and ifc.control is True: @@ -52,8 +52,8 @@ class OvsService(SdnService): # create virtual interfaces cfg += "ip link add rtr%s type veth peer name sw%s\n" % (ifnum, ifnum) - cfg += "ifconfig rtr%s up\n" % ifnum - cfg += "ifconfig sw%s up\n" % ifnum + cfg += "ip link set dev rtr%s up\n" % ifnum + cfg += "ip link set dev sw%s up\n" % ifnum # remove ip address of eths because quagga/zebra will assign same IPs to rtr interfaces # or assign them manually to rtr interfaces if zebra is not running