Subject: Re: always print IPv4 alias addresses
To: Erik E. Fair <email@example.com>
From: Michael Richardson <firstname.lastname@example.org>
Date: 04/29/2001 17:40:20
>>>>> "Erik" == Erik E Fair <email@example.com> writes:
Erik> At 16:42 -0700 4/27/01, Jason R Thorpe wrote:
>> Sounds good to me. The whole notion of "aliases" seems silly to me,
>> really... they're just addresses on an interface. I think the only
>> reason we have "alias" is because ifconfig and its ioctls were poorly
>> designed in the first place :-)
Erik> Um, well, there is the question of what IP address gets stuffed into
Erik> a packet without one (i.e. most applications don't bother to set one,
Erik> so you get one from the interface that the routing table decides to
Erik> send the packet out), and that marks the difference between the
Erik> interface's "address" and an "alias".
The outgoing address is picked via a route entry to that destination
just like in multihoming.
If you do:
ifconfig ep0 inet 192.0.0.1 up
ifconfig ep0 inet 184.108.40.206 netmask 255.255.255.0 alias
route add -net 220.127.116.11 18.104.22.168
and then connect to 22.214.171.124, then you will find that your source
address is 126.96.36.199, not 192.0.0.1.
Solidum Systems Corporation