From bf40c2768d6b6614cc0f1b4fb68ca011489e89d3 Mon Sep 17 00:00:00 2001 From: Phil Sutter Date: Mon, 11 Jun 2018 16:58:20 +0200 Subject: network-scripts: Replace brctl with ip-link Since ip-link has full support for Linux bridges (and slave ports), use that instead of the deprecated brctl from bridge-utils. --- network-scripts/ifdown-eth | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'network-scripts/ifdown-eth') diff --git a/network-scripts/ifdown-eth b/network-scripts/ifdown-eth index 97b17aaf..c610fd20 100755 --- a/network-scripts/ifdown-eth +++ b/network-scripts/ifdown-eth @@ -135,14 +135,13 @@ if [ -d "/sys/class/net/${REALDEVICE}" ]; then fi [ "$retcode" = "0" ] && retcode=$? -if [ -n "${BRIDGE}" ] && [ -x /usr/sbin/brctl ]; then - /sbin/ip link set dev ${DEVICE} down - /usr/sbin/brctl delif -- ${BRIDGE} ${DEVICE} +if [ -n "${BRIDGE}" ]; then + ip link set dev ${DEVICE} nomaster down # Upon removing a device from a bridge, # it's necessary to make radvd reload its config [ -r /run/radvd/radvd.pid ] && kill -HUP $(cat /run/radvd/radvd.pid) if [ -d /sys/class/net/${BRIDGE}/brif ] && [ $(ls -1 /sys/class/net/${BRIDGE}/brif | wc -l) -eq 0 ]; then - /usr/sbin/brctl delbr -- ${BRIDGE} + ip link del ${BRIDGE} fi fi -- cgit v1.2.1