[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: netmask of alias IP



I have assigned 2 alias IP to my computer
if I use 255.255.255.255 as netmask nothing works no more
this is my situation

/etc/hostname.fxp0
inet 192.84.x.y 255.255.255.0 NONE
inet alias 172.16.254.254 255.255.255.0 NONE
inet alias 172.16.253.254 255.255.255.0 NONE

AND THIS WORKS

if I set it like this
inet 192.84.x.y 255.255.255.0 NONE
inet alias 172.16.254.254 255.255.255.255 NONE
inet alias 172.16.253.254 255.255.255.255 NONE

the computers on the subnets 172.16.253.0 and 172.16.254.0 are not able
to being natted no more. I guess it is because of my nat rule ??

nat on fxp0 from 172.16.254.0/24 to any -> 192.84.x.y
nat on fxp0 from 172.16.253.0/24 to any -> 192.84.x.y

thanks

Rick

On Wed, 3 Jul 2002, OpenBSD mailing user :: JGM wrote:

> On Wed, Jul 03, 2002 at 08:00:35AM -0600, RJ45 wrote:
> > Hello,
> > what is the correct netmask to assign using ifconfig on an alias IP
> > Address ?? is it 255.255.255.255 or it must be the same netmask as the
> > primary IP address assigned to the interface ??
> > 
> > thanks
> > 
> > Rick
> > 
> 
> # cat /etc/hostname.xl0
> inet 192.168.1.3 255.255.255.0 NONE 
> inet alias 192.168.1.30 255.255.255.255 
> 
> 
> 
>  .--==-=-----------------=====---=-=----.
> /  :.::..: OpenBSD mailing user :..::.:  \
> \  :.:<obsd_(_at_)_jgm_(_dot_)_gov_(_dot_)_ar>.:.CIT.::.JGM.::  /
>  `==----========---=============----==-='