aboutsummaryrefslogtreecommitdiffstats
path: root/sysconfig/network-scripts/ifup-routes
diff options
context:
space:
mode:
authorBill Nottingham <notting@redhat.com>2001-03-05 20:32:23 +0000
committerBill Nottingham <notting@redhat.com>2001-03-05 20:32:23 +0000
commit188cd3c51890943d2c715b60730a2b1437111226 (patch)
treea734472c14f9f49344b5075ba4f2bf2a61a1f038 /sysconfig/network-scripts/ifup-routes
parent1099ac3c2884ea0d4a607afa68630172e192d48a (diff)
downloadinitscripts-188cd3c51890943d2c715b60730a2b1437111226.tar
initscripts-188cd3c51890943d2c715b60730a2b1437111226.tar.gz
initscripts-188cd3c51890943d2c715b60730a2b1437111226.tar.bz2
initscripts-188cd3c51890943d2c715b60730a2b1437111226.tar.xz
initscripts-188cd3c51890943d2c715b60730a2b1437111226.zip
- don't attempt to work around broken linuxconf routes, simplify
(and make consistent) adding of static routes, and make it work again for aliases (#29500, #29549)
Diffstat (limited to 'sysconfig/network-scripts/ifup-routes')
-rwxr-xr-xsysconfig/network-scripts/ifup-routes10
1 files changed, 3 insertions, 7 deletions
diff --git a/sysconfig/network-scripts/ifup-routes b/sysconfig/network-scripts/ifup-routes
index 580b4d6e..61e209c9 100755
--- a/sysconfig/network-scripts/ifup-routes
+++ b/sysconfig/network-scripts/ifup-routes
@@ -15,13 +15,9 @@ if [ ! -f /etc/sysconfig/static-routes ]; then
fi
#note the trailing space in the grep gets rid of aliases
-grep "^$1 " /etc/sysconfig/static-routes | while read device args; do
+grep "^$DEVICE " /etc/sysconfig/static-routes | while read device args; do
/sbin/route add -$args $device
done
-grep "^any " /etc/sysconfig/static-routes | while read ignore type net netmask mask gw dev ; do
- if [ "$dev" = "$1" ]; then
- /sbin/route add -$type $net $netmask $mask $dev
- elif [ "$gw" = "gw" ]; then
- /sbin/route add -$type $net $netmask $mask $gw $dev
- fi
+grep "^any " /etc/sysconfig/static-routes | while read ignore args ; do
+ /sbin/route add -$args
done