View topic - ifconfig alias problem

ifconfig alias problem

Read-only archive of qnx.qnx4 (General QNX4 Discussion Group) at inn.qnx.com

ifconfig alias problem

Postby jpal » Fri Mar 23, 2007 2:38 pm

In other os's (e.g. windows) you have the possibility
to set more then one IP-address for one interface.
For this purpose there is
ifconfig <interface> alias <IP-address>
utility in TCP/IP V4.2x.
Unfortunately this possibility is not perfect.
For example the IP-addresses are the following:

ifconfig en1 192.168.17.2
ifconfig en1 alias 192.168.16.2

Let suppose, there is a foreign host on the network 192.168.16
having the IP-address 192.168.16.17.

In this case the echo request works perfectly:

Source Destination Protocol Info
192.168.16.2 192.168.16.17 ICMP Echo (ping) request
192.168.16.17 192.168.16.2 ICMP Echo (ping) reply
192.168.16.2 192.168.16.17 ICMP Echo (ping) request
192.168.16.17 192.168.16.2 ICMP Echo (ping) reply

The higher layer does not work perfectly, because the destination
address equals to the primary address of the interface (i.e.
192.168.17.2), for example:

Source Destination Protocol Info
192.168.17.2 192.168.16.17 TCP 1026 > telnet ...
192.168.16.17 192.168.17.2 TCP telnet > 1026 ...
192.168.17.2 192.168.16.17 TELNET Telnet Data ...
192.168.16.17 192.168.17.2 TELNET Telnet Data ...

If you have luck, there is no default gateway set for the foreign
host, so some applications, e.g. telnet or netprint can work. If there
is a gateway address set for the foreign host, all the replies will be
sent to the gateway, so no answer will be given.

Questions: Is this phenomenon mentioned above is a bug or a feature of
the TCP/IP V4.2x? Is there any other way to set more then one
IP-addresses for one interface?

TIA: Jozsef Pal
-------------------------------------------------------------
_ _ _ _ _ _ _
| | | _| |_ |_ |_ |_| |_| |
|_| |_| |_ _| |_ | | | | |_

Jozsef Pal, Ph.D.El.Eng. Voice: +36 1 457-82-26
VEIKI Research Institute Fax: +36 1 457-82-28
Division for Control Engineering Mobil: +36 30 960-69-23
H-1251 Budapest, P.O.B. 80. Email: j.pal@veiki.hu
HUNGARY Web: http://www.veiki.hu
jpal
Active Member
 
Posts: 16
Joined: Mon Jul 07, 2003 2:08 pm

Return to qnx.qnx4

Who is online

Users browsing this forum: No registered users and 1 guest

cron