Subject: Re: inet aliases and routed
To: Gregory McGarry <g.mcgarry@ieee.org>
From: Andrew Gillham <gillham@vaultron.com>
List: current-users
Date: 08/16/2000 22:33:26
Gregory McGarry writes:
> Andrew Brown wrote:
>
> > (1) what's the correct method for adding aliases via rc.d
> > configuration? what i've got now is:
> >
> > # cat /etc/ifconfig.ex0
> > 204.17.3.77 netmask 0xffffff00 media autoselect
> > alias 204.17.3.69
> >
> > but i've just noticed that i can't reach (ie, ping or telnet) the
> > alias from the machine itself.
>
> I applied a recent kame patch to a 1.4.2 system and saw the same
> result. I wasn't expecting it.
You need a route via the loopback to make this work. This should be
added automatically if you use /etc/ifaliases. I believe 'ifconfig' adds
this automatically when you add the "primary" address.
(e.g. my machine has a route via loopback for it's primary ethernet's
ip address)
'route add $alias 127.0.0.1'
-Andrew