aboutsummaryrefslogtreecommitdiffstats
path: root/sysconfig/network-scripts/ifdown
diff options
context:
space:
mode:
authorBill Nottingham <notting@redhat.com>2003-01-31 21:28:49 +0000
committerBill Nottingham <notting@redhat.com>2003-01-31 21:28:49 +0000
commitff69fd0f08a9e0d9c28a3345076dd947e1de6bf2 (patch)
tree28aed9a16cd4d9890d268fa039bdf1e03796ef70 /sysconfig/network-scripts/ifdown
parent8c3dbdebbec6c2eb636b8a5654a5adbb99592716 (diff)
downloadinitscripts-ff69fd0f08a9e0d9c28a3345076dd947e1de6bf2.tar
initscripts-ff69fd0f08a9e0d9c28a3345076dd947e1de6bf2.tar.gz
initscripts-ff69fd0f08a9e0d9c28a3345076dd947e1de6bf2.tar.bz2
initscripts-ff69fd0f08a9e0d9c28a3345076dd947e1de6bf2.tar.xz
initscripts-ff69fd0f08a9e0d9c28a3345076dd947e1de6bf2.zip
802.1Q VLAN support (<tis@foobar.fi>, #82593)r7-05
Diffstat (limited to 'sysconfig/network-scripts/ifdown')
-rwxr-xr-xsysconfig/network-scripts/ifdown10
1 files changed, 10 insertions, 0 deletions
diff --git a/sysconfig/network-scripts/ifdown b/sysconfig/network-scripts/ifdown
index 992fd5ae..29fb9674 100755
--- a/sysconfig/network-scripts/ifdown
+++ b/sysconfig/network-scripts/ifdown
@@ -122,4 +122,14 @@ if [ "$retcode" = 0 ] ; then
# the interface went down.
fi
+if [ -n "$VLAN" -a -x /sbin/vconfig ]; then
+ # 802.1q VLAN
+ if echo ${DEVICE} | LANG=C egrep -v '(:)' | LANG=C egrep -q 'eth[0-9][0-9]*\.[0-9][0-9]?[0-9]?[0-9]?' ; then
+ [ -f /proc/net/vlan/${DEVICE} ] && {
+ /sbin/vconfig rem ${DEVICE}
+ retcode=$?
+ }
+ fi
+fi
+
exit $retcode