aboutsummaryrefslogtreecommitdiffstats
path: root/sysconfig
diff options
context:
space:
mode:
authorPhil Knirsch <pknirsch@redhat.com>2002-07-04 14:54:54 +0000
committerPhil Knirsch <pknirsch@redhat.com>2002-07-04 14:54:54 +0000
commitb527b8be3163f65ad714369120534db41366e803 (patch)
treeb8119e6adc859f48a3962bbd5ba0502822219ed3 /sysconfig
parent14cf69cf888c13caa8f2e26b0173ceb352cd7a31 (diff)
downloadinitscripts-b527b8be3163f65ad714369120534db41366e803.tar
initscripts-b527b8be3163f65ad714369120534db41366e803.tar.gz
initscripts-b527b8be3163f65ad714369120534db41366e803.tar.bz2
initscripts-b527b8be3163f65ad714369120534db41366e803.tar.xz
initscripts-b527b8be3163f65ad714369120534db41366e803.zip
- Fixed ifup-route to use new /etc/sysconfig/network-scripts/route-DEV files.
Diffstat (limited to 'sysconfig')
-rwxr-xr-xsysconfig/network-scripts/ifup-routes19
1 files changed, 11 insertions, 8 deletions
diff --git a/sysconfig/network-scripts/ifup-routes b/sysconfig/network-scripts/ifup-routes
index 2ce874c8..c997a68d 100755
--- a/sysconfig/network-scripts/ifup-routes
+++ b/sysconfig/network-scripts/ifup-routes
@@ -8,17 +8,20 @@ if [ "$1" = "" ]; then
exit 1
fi
-if [ ! -f /etc/sysconfig/networking/static-routes ] &&
- [ ! -f /etc/sysconfig/static-routes ]; then
+if [ ! -f /etc/sysconfig/network-scripts/route-$1 ]; then
exit 0
fi
DEVICE=$1
-#note the trailing space in the grep gets rid of aliases
-grep "^$DEVICE[[:space:]]" /etc/sysconfig/static-routes | while read device args; do
- /sbin/route add -$args $device
-done
-grep "^any[[:space:]]" /etc/sysconfig/static-routes | while read ignore args ; do
- /sbin/route add -$args
+# Only use the new route-DEV style.
+cat "/etc/sysconfig/network-scripts/route-$DEVICE" | while read line; do
+ echo "/sbin/ip route add $line"
done
+
+#grep "^$DEVICE[[:space:]]" /etc/sysconfig/static-routes | while read device args; do
+# /sbin/route add -$args $device
+#done
+#grep "^any[[:space:]]" /etc/sysconfig/static-routes | while read ignore args ; do
+# /sbin/route add -$args
+#done