aboutsummaryrefslogtreecommitdiffstats
path: root/rc.d
diff options
context:
space:
mode:
Diffstat (limited to 'rc.d')
-rwxr-xr-xrc.d/init.d/network15
1 files changed, 14 insertions, 1 deletions
diff --git a/rc.d/init.d/network b/rc.d/init.d/network
index e7fd388f..fc8237b8 100755
--- a/rc.d/init.d/network
+++ b/rc.d/init.d/network
@@ -33,6 +33,9 @@ fi
# Even if IPX is configured, without the utilities we can't do much
[ ! -x /sbin/ipx_internal_net -o ! -x /sbin/ipx_configure ] && IPX=
+# Even if VLAN is configured, without the utility we can't do much
+[ ! -x /sbin/vconfig ] && VLAN=
+
# If IPv6 is explicitly configured, make sure it's available.
if [ "$NETWORKING_IPV6" = "yes" ]; then
alias=`modprobe -c | awk '/^alias net-pf-10 / { print $3 }'`
@@ -50,7 +53,7 @@ cd /etc/sysconfig/network-scripts
# ignore aliases, alternative configurations, and editor backup files
interfaces=`ls ifcfg* | LANG=C egrep -v '(ifcfg-lo|:|rpmsave|rpmorig|rpmnew)' | \
LANG=C egrep -v '(~|\.bak)$' | \
- LANG=C egrep 'ifcfg-[A-Za-z0-9_-]+$' | \
+ LANG=C egrep 'ifcfg-[A-Za-z0-9\._-]+$' | \
sed 's/^ifcfg-//g'`
# See how we were called.
@@ -78,6 +81,16 @@ case "$1" in
;;
esac
+ case "$VLAN" in
+ yes|true)
+ if [ -d /proc/net/vlan ] || modprobe 8021q >/dev/null 2>&1 ; then
+ action $"Setting 802.1Q VLAN parameters: " /sbin/vconfig set_name_type DEV_PLUS_VID_NO_PAD
+ else
+ echo $"No 802.1Q VLAN support available in kernel."
+ fi
+ ;;
+ esac
+
oldhotplug=`sysctl kernel.hotplug 2>/dev/null | \
awk '{ print $3 }' 2>/dev/null`
sysctl -w kernel.hotplug="/bin/true" > /dev/null 2>&1