diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 1997-02-03 12:04:45 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 1997-02-03 12:04:45 +0000 |
commit | 2677daedb89550ab773f8d5cf522a92e5a22fc2b (patch) | |
tree | cfffe1e2e04c70c65127465635391c0cd656c24a /etc | |
parent | 54b37d2145bab4dd16bb1058a36066f669f96282 (diff) |
do ifaliases after /usr/bin exists in nfs diskless env; pr#77, matthieu@laas.fr
Diffstat (limited to 'etc')
-rw-r--r-- | etc/netstart | 19 | ||||
-rw-r--r-- | etc/rc | 18 |
2 files changed, 18 insertions, 19 deletions
diff --git a/etc/netstart b/etc/netstart index b21ba9f8e9e..7825960d477 100644 --- a/etc/netstart +++ b/etc/netstart @@ -1,6 +1,6 @@ #!/bin/sh - # -# $OpenBSD: netstart,v 1.12 1996/11/02 00:52:02 deraadt Exp $ +# $OpenBSD: netstart,v 1.13 1997/02/03 12:04:44 deraadt Exp $ # set these to "NO" to turn them off. otherwise, they're used as flags routed_flags=-q @@ -120,20 +120,3 @@ route add -net 224.0.0.0 -interface $hostname if [ -f /etc/mygate ]; then route add default `cat /etc/mygate` fi - -# /etc/ifaliases, if it exists, contains the names of additional IP -# addresses for each interface. It is formatted as a series of lines -# that contain -# interface address netmask -if [ -f /etc/ifaliases ]; then -( - # delete comments and blank lines - set -- `sed -e 's/#.*$//' /etc/ifaliases | grep -v '^$'` - - while [ $# -ge 3 ] ; do - ifconfig $1 inet alias $2 netmask $3 - route add $2 localhost - shift 3 - done -) -fi @@ -1,4 +1,4 @@ -# $OpenBSD: rc,v 1.28 1996/12/22 20:14:09 deraadt Exp $ +# $OpenBSD: rc,v 1.29 1997/02/03 12:04:44 deraadt Exp $ # System startup script run by init on autoboot # or after single-user. @@ -76,6 +76,22 @@ echo 'starting network' mount /usr >/dev/null 2>&1 mount /var >/dev/null 2>&1 +# /etc/ifaliases, if it exists, contains the names of additional IP +# addresses for each interface. It is formatted as a series of lines +# that contain +# interface address netmask +if [ -f /etc/ifaliases ]; then +( + # delete comments and blank lines + set -- `sed -e 's/#.*$//' /etc/ifaliases | grep -v '^$'` + while [ $# -ge 3 ] ; do + ifconfig $1 inet alias $2 netmask $3 + route add $2 localhost + shift 3 + done +) +fi + if [ X"${ipfilter}" = X"YES" -a X"${ipmon_flags}" != X"NO" ]; then ipmon ${ipmon_flags} & fi |