Subject: bin/261: netstart can't run ifconfig with extras w/o broadcast.
To: None <gnats-admin>
From: Bill Sommerfeld <sommerfeld@localhost.medford.ma.us>
List: netbsd-bugs
Date: 05/23/1994 07:20:05
>Number:         261
>Category:       bin
>Synopsis:       netstart can't run ifconfig with extras w/o broadcast.
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    gnats-admin (Utility Bug People)
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Mon May 23 07:20:04 1994
>Originator:     Bill Sommerfeld
>Organization:
	none
>Release:        
>Environment:
	<machine, os, target, libraries (multiple lines)>
System: NetBSD orchard.medford.ma.us NetBSD 0.9B NetBSD 0.9B (ORCHARD) #0: Wed May 18 13:27:51 EDT 1994 sommerfeld@orchard.medford.ma.us:/u1/nsys/sys/arch/i386/compile/ORCHARD i386


>Description:
	with -current as of May 18, using the "broadcast" keyword for
	ifconfig on the sl0 interface clobbers the destination address.

	netstart won't let you use "extras" if you don't have a
	broadcast address.

>How-To-Repeat:
	cat > /etc/hostname.sl << EOF
	inet <addr> <mask> <bcast> link0 link1
	dest <dest>
	EOF
	/etc/netstart
	ifconfig sl0

	note that the "dest" address of sl0 is set to the all-1's
	subnet broadcast address

>Fix:
	Apply following change to /etc/netstart to allow the use of
"NONE" in the bcaddr column as a placebo.  You may want to do the
same for the netmask.

*** /etc/netstart	Mon May 23 09:48:34 1994
--- /src/etc/netstart	Tue May 17 10:22:44 1994
***************
*** 77,83 ****
  	    cmd="ifconfig $1 $af $name "
  	    if [ "${dt}" = "dest" ]; then cmd="$cmd $dtaddr"; fi
  	    if [ -n "$mask" ]; then cmd="$cmd netmask $mask"; fi
! 	    if [ -n "$bcaddr" -a "X$bcaddr" != "XNONE" ]; then cmd="$cmd broadcast $bcaddr"; fi
  	    cmd="$cmd $extras"
  
  	    $cmd
--- 77,83 ----
  	    cmd="ifconfig $1 $af $name "
  	    if [ "${dt}" = "dest" ]; then cmd="$cmd $dtaddr"; fi
  	    if [ -n "$mask" ]; then cmd="$cmd netmask $mask"; fi
! 	    if [ -n "$bcaddr" ]; then cmd="$cmd broadcast $bcaddr"; fi
  	    cmd="$cmd $extras"
  
  	    $cmd

>Audit-Trail:
>Unformatted:
SEND-PR: -*- send-pr -*-
SEND-PR: Lines starting with `SEND-PR' will be removed automatically, as
SEND-PR: will all comments (text enclosed in `<' and `>').
SEND-PR: 
SEND-PR: Please consult the send-pr man page `send-pr(1)' or the Texinfo
SEND-PR: manual if you are not sure how to fill out a problem report.
SEND-PR:
SEND-PR: Choose from the following categories:
SEND-PR:
SEND-PR: bin        kern       lib        misc       port-amiga 
SEND-PR: port-hp300 port-i386  port-m68k  port-mac   port-sparc 
SEND-PR: port-sun3  
SEND-PR:
To: gnats-bugs@sun-lamp.cs.berkeley.edu
Subject: 
From: sommerfe
Reply-To: sommerfe



------------------------------------------------------------------------------