network configuration / routing

2007-12-25 5:26:00

Hello List

Lets say I have one interface in my machine

qfe0: flags=1000843<UP,BROADCAST,RUNNING,MULTICAST,IPv4> mtu 1500 index 3
inet 192.168.1.1 netmask ffffff00 broadcast 192.168.1.255

and an virtual interface qfe0:1 plumbed

qfe0:1: flags=1000843<UP,BROADCAST,RUNNING,MULTICAST,IPv4> mtu 1500 index 3
inet 192.168.1.2 netmask ffffff00 broadcast 192.168.1.255

and this routing table

Routing Table: IPv4
Destination Gateway Flags Ref Use Interface
-------------------- -------------------- ----- ----- ------ ---------
192.168.1.0 192.168.1.1 U 1 46816 qfe0
224.0.0.0 192.168.1.1 U 1 0 qfe0
default 192.168.1.254 UG 1 67797
127.0.0.1 127.0.0.1 UH 1152195839 lo0

Now I would like to communicate with host 192.168.1.50

but the host shouldn't use 192.168.1.1 as source address, but
192.168.1.2 when communicating with 192.168.1.50

for all other connections it should use 192.168.1.1

is this possible ?

kr
Christian

Comments

Got something to say?

You must be logged in to post a comment.