Mark Seiden wrote:
> 
> it is driving me crazy why a seemingly identical command
> is not correctly executed in these two cases.  does anyone
> understand the problem?



Yes I see it now that you quoted the offending command.
The syntax is crap :)


Wrong
---------
ifconfig $IFNAME $IPADDR ${MASK:+netmask $MASK} ${ETHER:+hw $ETHER} 
${BROADCAST:+broadcast $BROADCAST} $STATE


Correct
----------
ifconfig $IFNAME $IPADDR ${MASK:+netmask} $MASK ${ETHER:+hw} $ETHER 
${BROADCAST:+broadcast} $BROADCAST $STATE


I tried this on the Oxygen machine in my own test script and
it works my way but fails David's way.  Set -x didn't show
any difference in the command that was to be run.



 
> i have no problem with the gateway setting.  perhaps you inadvertantly
> munged or removed the GATEWAY_IFNAME definition, which is required.
> arguably it should default on a one interface machine, but it doesn't.
> maybe you deleted the newline at the end of the file, e.g.


Odd, it's there now, and there are more routes than before.
The routes look ok, though, just a couple of host routes
that took me a second to decipher. Must have been operator 
error. :)

If this mail makes it to the list, then my feeble ipchains
masq rule worked and Oxygen works, too.  W00t!


Thanks for the heads up,
Matthew






 
> On Sat, Mar 24, 2001 at 05:23:51PM -0800, Matthew Schalit wrote:
> > Mark Seiden wrote:
> > >
> > > i had this problem also.
> > >
> > > i still don't understand why it's happening.
> > >
> > > you might notice that i've added an IF_BROADCAST variable as
> > > well to network.conf...
> > >
> > > i dare say that with a class c netmask and a class a address ifconfig
> > > will get your broadcast address wrong, also.
> > >
> > > here's a bit of code that works around in /etc/init.d/network
> > >
> > >         echo -n "network: bringing $STATE interface $IFNAME on $IPADDR"
> > >         [ -n "$MASK" ] && echo -n " with netmask $MASK"
> > >         [ -n "$BROADCAST" ] && echo -n " with broadcast address $BROADCAST"
> > >         [ -n "$ETHER" ] && echo -n " (with hardware address $ETHER)"
> > >         echo
> > >
> > > # what a weird bug:  ifconfig complains "netmask... unknown host".
> > > #       ifconfig $IFNAME $IPADDR ${MASK:+netmask $MASK} ${ETHER:+hw $ETHER} 
>${BROADCAST:+broadcast $BROADCAST} $STATE
> > > # but this works:
> > > echo ifconfig $IFNAME $IPADDR ${MASK:+netmask $MASK} ${ETHER:+hw $ETHER} 
>${BROADCAST:+broadcast $BROADCAST} $STATE | sh
> > >         }
> > >
> >
> >
> >
> >
> > Thanks for the workaround ideas, Mark.
> > Have you noticed that the default gateway is not getting
> > added to the routing table?  It wasn't in mine even
> > though it was entered in /etc/network.conf.  I haven't
> > had time to track it down though.
> >
> > Matthew
> >
> > _______________________________________________
> > Leaf-devel mailing list
> > [EMAIL PROTECTED]
> > http://lists.sourceforge.net/lists/listinfo/leaf-devel
> 
> --
> mark seiden, [EMAIL PROTECTED], 1-(650) 592 8559 (voice) Pacific Time Zone
> 
> _______________________________________________
> Leaf-devel mailing list
> [EMAIL PROTECTED]
> http://lists.sourceforge.net/lists/listinfo/leaf-devel

_______________________________________________
Leaf-devel mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/leaf-devel

Reply via email to