summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJudd Vinet <judd@archlinux.org>2002-04-16 03:59:06 +0000
committerJudd Vinet <judd@archlinux.org>2002-04-16 03:59:06 +0000
commitf5e0fa814e1f31279509645a25057dcefa5eaadc (patch)
treea0e24500a1d38e32058d069f772d23476005c655
parent8bc78f134bf719b16a3b3b2a7cea947fbf526e3b (diff)
Updated network rc script with jproctor's disable-eth changes0.2
-rwxr-xr-xnetwork17
1 files changed, 13 insertions, 4 deletions
diff --git a/network b/network
index 2699230..64a23c0 100755
--- a/network
+++ b/network
@@ -3,24 +3,33 @@
. /etc/rc.conf
. /etc/rc.d/functions
+
case "$1" in
start)
stat_busy "Starting Network"
for ifline in "${IF_UP[@]}"; do
- /sbin/ifconfig $ifline || stat_die
+ if [[ `echo $ifline | grep '^[^\!]' | wc -l` -eq 1 ]]; then
+ /sbin/ifconfig $ifline || stat_die
+ fi
done
for rtline in "${ROUTE_UP[@]}"; do
- /sbin/route $rtline || stat_die
+ if [[ `echo $rtline | grep '^[^\!]' | wc -l` -eq 1 ]]; then
+ /sbin/route $rtline || stat_die
+ fi
done
stat_done
;;
stop)
stat_busy "Stopping Network"
for rtline in "${ROUTE_DN[@]}"; do
- /sbin/route $rtline || stat_die
+ if [[ `echo $rtline | grep '^[^\!]' | wc -l` -eq 1 ]]; then
+ /sbin/route $rtline || stat_die
+ fi
done
for ifline in "${IF_DN[@]}"; do
- /sbin/ifconfig $ifline || stat_die
+ if [[ `echo $ifline | grep '^[^\!]' | wc -l` -eq 1 ]]; then
+ /sbin/ifconfig $ifline || stat_die
+ fi
done
stat_done
;;