diff options
| author | Bill Nottingham <notting@redhat.com> | 2006-06-30 20:02:42 +0000 |
|---|---|---|
| committer | Bill Nottingham <notting@redhat.com> | 2006-06-30 20:02:42 +0000 |
| commit | 98ff30f0077b9fe78ba1ddda1dc7cc6faaa17188 (patch) | |
| tree | 49bd05bca4723cf3f80cb2fe2bffb217ab5548c0 /sysconfig/network-scripts/ifdown-eth | |
| parent | 4d0100d922a1935a23ec5ba826fc2cea60d3d41f (diff) | |
backport bridge fixes (#187100)
Diffstat (limited to 'sysconfig/network-scripts/ifdown-eth')
| -rwxr-xr-x | sysconfig/network-scripts/ifdown-eth | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/sysconfig/network-scripts/ifdown-eth b/sysconfig/network-scripts/ifdown-eth index 55c02fbd..6651c93f 100755 --- a/sysconfig/network-scripts/ifdown-eth +++ b/sysconfig/network-scripts/ifdown-eth @@ -26,8 +26,11 @@ if [ -n "${BRIDGE}" -a -x /usr/sbin/brctl ]; then # Upon removing a device from a bridge, # it's necessary to make radvd reload its config [ -r /var/run/radvd/radvd.pid ] && kill -HUP `cat /var/run/radvd/radvd.pid` + if LC_ALL=C /usr/sbin/brctl show | LC_ALL=C grep -q "^${BRIDGE} .*can't get port info"; then + /usr/sbin/brctl delbr ${BRIDGE} + fi exit 0 -fi +fi . /etc/sysconfig/network @@ -108,10 +111,6 @@ if [ "$retcode" = 0 ] ; then # the interface went down. fi -if [ "$TYPE" = "Bridge" -a -x /usr/sbin/brctl ]; then - /usr/sbin/brctl delbr ${DEVICE} -fi - if [ -n "$VLAN" -a -x /sbin/vconfig ]; then # 802.1q VLAN if echo ${DEVICE} | LANG=C egrep -v '(:)' | LANG=C egrep -q '(eth|bond)[0-9][0-9]*\.[0-9][0-9]?[0-9]?[0-9]?' \ |
