From 91fd228098bf5650701c1b86817c3b1d1be1056f Mon Sep 17 00:00:00 2001 From: Bill Nottingham Date: Mon, 12 Apr 1999 16:59:18 +0000 Subject: remove 2.0 kernel support --- sysconfig/network-scripts/ifup | 2 +- sysconfig/network-scripts/ifup-aliases | 13 ++----------- 2 files changed, 3 insertions(+), 12 deletions(-) diff --git a/sysconfig/network-scripts/ifup b/sysconfig/network-scripts/ifup index bfbe03bd..e106071e 100755 --- a/sysconfig/network-scripts/ifup +++ b/sysconfig/network-scripts/ifup @@ -106,7 +106,7 @@ else # don't re-add subnet route on 2.2 kernels, but add a route # to a non-local subnet. # stupid hack, but it should work - if [ "$ISALIAS" = no ] && grep -q " 2.0" /proc/version || [ -z "`route -n | sed "s/ .*//" | grep ${NETWORK}`" ]; then + if [ "$ISALIAS" = no ] && [ -z "`route -n | sed "s/ .*//" | grep ${NETWORK}`" ]; then route add -net ${NETWORK} netmask ${NETMASK} ${DEVICE} else route add -host ${IPADDR} ${DEVICE} diff --git a/sysconfig/network-scripts/ifup-aliases b/sysconfig/network-scripts/ifup-aliases index ad4d195c..7e06b489 100755 --- a/sysconfig/network-scripts/ifup-aliases +++ b/sysconfig/network-scripts/ifup-aliases @@ -13,10 +13,6 @@ if [ -x /bin/linuxconf -a -f /usr/lib/libncurses.so.4.2 ] ; then # add # del # reload - KERN20= - if uname -r | grep -q "^2\.0"; then - KERN20=true - fi linuxconf --hint ipalias $1 | while read verb arg1 arg2 arg3 arg4; do case $verb in add) @@ -27,16 +23,11 @@ if [ -x /bin/linuxconf -a -f /usr/lib/libncurses.so.4.2 ] ; then # new linuxconf /sbin/ifconfig $arg1 $arg2 netmask $arg3 broadcast $arg4 fi - [ -n "$KERN20" ] && /sbin/route add $arg2 $arg1 ;; del) - # the - 0.0.0.0 tells the kernel to remove the device + # the 0.0.0.0 tells the kernel to remove the device # it is necessary to remove it in order for reload to work. - if [ -n "$KERN20" ]; then - /sbin/ifconfig ${arg1}- 0.0.0.0 - else - /sbin/ifconfig ${arg1} 0.0.0.0 - fi + /sbin/ifconfig ${arg1} 0.0.0.0 ;; reload) echo $arg1 > /proc/sys/net/core/net_alias_max -- cgit v1.2.1