[ previous ] [ next ] [ threads ]
 
 From:  "Manuel Kasper" <mk at neon1 dot net>
 To:  "Christiaens Joachim" <jchristi at oce dot be>
 Cc:  m0n0wall at lists dot m0n0 dot ch
 Subject:  Re: [m0n0wall] Strange behaviour
 Date:  Thu, 16 Oct 2003 19:04:57 +0200 (CEST)
Christiaens Joachim said:
> All works well, but the WAN interface shows 255.255.255.255 as subnet
> mask,
> while this should be 255.255.254.0 (/23)...

Looking at your config.xml, it seems that you've configured your WAN
interface with a /24 subnet mask, not /23.

> ***** Interfaces *****
> sis0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500
> 	inet 10.32.1.11 netmask 0xffffff00 broadcast 10.32.1.255
> 	inet 10.32.1.34 netmask 0xffffffff broadcast 10.32.1.34

That's perfectly OK. The first/primary IP address has the /24 netmask, and
the alias (10.32.1.34) has /32. It has got to be that way, if you don't
believe, try something like this in plain FreeBSD:

ifconfig sis1 192.168.1.1/24
ifconfig sis1 192.168.1.2/24 alias

--> ifconfig: ioctl (SIOCAIFADDR): File exists

From man ifconfig(8):

"If the address is on the same subnet as the first network address for
this interface, a non-conflicting netmask must be given. Usually
0xffffffff is most appropriate."

- Manuel