diff options
author | rgrimes <rgrimes@FreeBSD.org> | 1995-05-17 04:46:57 +0000 |
---|---|---|
committer | rgrimes <rgrimes@FreeBSD.org> | 1995-05-17 04:46:57 +0000 |
commit | 037b95c21c474703d3d472125943753d6700da3c (patch) | |
tree | d1778f3d607543f0103c8cb520715159aad2de39 /etc/netstart | |
parent | 4e892ff3aaa2c34a7d583deac329272eddfac76c (diff) | |
download | FreeBSD-src-037b95c21c474703d3d472125943753d6700da3c.zip FreeBSD-src-037b95c21c474703d3d472125943753d6700da3c.tar.gz |
Reviewed by: bde, jkh
Add comment that you should not have to edit netstart, and if you
do we would like to know about it.
The lo0 interface is now handled just like any other interface,
This makes it possible to do things to it from sysconfig.
Redo the comments in sysconfig about network_interfaces and ifconfig_${X}
to reflect the moving of lo0 to this scheme. We now have an uncommented
variable for sysintall to find and play with. (Your welcome Jordan)
Redo the way static routes are handled. Basically use the same
scheme for routes that I did for network interfaces. This allows
any number of static routes to be added from sysconfig.
Make sure we do the default route first so we stand a chance of
getting to our DNS server (if we have one) to resolve our own
IP address from $hostname.
Diffstat (limited to 'etc/netstart')
-rwxr-xr-x | etc/netstart | 22 |
1 files changed, 10 insertions, 12 deletions
diff --git a/etc/netstart b/etc/netstart index dfdccaf..5479527 100755 --- a/etc/netstart +++ b/etc/netstart @@ -1,11 +1,12 @@ #!/bin/sh - # -# $Id: netstart,v 1.30 1995/05/11 19:08:36 rgrimes Exp $ +# $Id: netstart,v 1.31 1995/05/11 21:11:14 jkh Exp $ # From: @(#)netstart 5.9 (Berkeley) 3/30/91 # Note that almost all the user-configurable behavior is no longer in # this file, but rather in /etc/sysconfig. Please check this file -# first before contemplating any changes here. +# first before contemplating any changes here. If you do need to change +# this file for some reason, we would like to know about it. # If there is a global system configuration file, suck it in. if [ -f /etc/sysconfig ]; then @@ -42,19 +43,16 @@ for ifn in ${network_interfaces}; do ifconfig ${ifn} done -# set the address for the loopback interface -ifconfig lo0 inet localhost - -# set interface for multicasts to default interface -# this needs to happen before router discovery -route add 224.0.0.0 -netmask 0xf0000000 -interface $hostname - if [ -n "$defaultrouter" -a "x$defaultrouter" != "xNO" ] ; then - route add default $defaultrouter + static_routes="default ${static_routes}" + route_default="default ${defaultrouter}" fi -# use loopback, not the wire -# route add $hostname localhost +# Set up any static routes. This should be done before router discovery. +for i in ${static_routes}; do + eval route_args=\$route_${i} + route add ${route_args} +done if [ "x$gated" != "xNO" -o "x$routedflags" != "xNO" ] ; then echo -n starting routing daemons: |