Operating System - HP-UX
1834882 Members
2559 Online
110071 Solutions
New Discussion

Re: about ip_strong_es_model and multiple default gateway

 
Xiang Zhao_1
Advisor

about ip_strong_es_model and multiple default gateway

Hi,

I tried the following on both a hpux 11.0 and hpux 11i box without success.
Please see the attached JPEG file for the topology.
Suppose the box has two network card lan1, lan2, each connected to a layer 4 switch

(load balancer).
lan1's ip is 192.168.1.100.
lan2's ip is 192.168.2.100.
and I added two default gateway as follows:
route add default 192.168.1.1 1
route add default 192.168.2.1 1
(192.168.1.1 and 192.168.2.1 are the ip for the two layer 4 switch)
I also use ndd -set /dev/ip ip_strong_es_model 1 to enable the strong es model.
However, when the client access the virtual service in the two layer 4 switches, the

default gateway chosen is random, sometimes it's 192.168.1.1, sometimes is

192.168.2.1. So only one layer 4 switch is working.
What I really want is that when the client access 192.168.1.100, the default route

should be 192.168.1.1 while if the client access 192.168.2.100, the default route

should be 192.168.2.1, then both layer 4 switch will be working.

BTW, the application running on the box is not binding to a specific ip address.

Is there something wrong? or I just midunderstand the paramter ip_strong_es_model.

Thanks in advance.
-Xiang
5 REPLIES 5
Sandman!
Honored Contributor

Re: about ip_strong_es_model and multiple default gateway

Are those network interface cards (NICs) lan1 and lan2 on separate LAN segments? They need to be distinct for your scenario to work.

From your post it looks like they are on the same LAN unless you have subnetted them differently. Could you post the output of your routing table as well the output of ifconfig on each of the lan cards.

thanks
Xiang Zhao_1
Advisor

Re: about ip_strong_es_model and multiple default gateway

lan1 and lan2 are on two differnet subnets.

netstat -nr:
Routing tables
Dest/Netmask Gateway Flags Refs Use Interface Pmtu
127.0.0.1 127.0.0.1 UH 0 7814663 lo0 4136
192.168.2.100 192.168.2.100 UH 0 157 lan2 4136
192.168.1.100 192.168.1.100 UH 0 6235842 lan1 4136
192.168.2.0 192.168.2.100 U 2 0 lan2 1500
192.168.1.0 192.168.1.100 U 2 0 lan1 1500
default 192.168.1.1 UG 0 0 lan1 1500
default 192.168.2.1 UG 0 0 lan2 1500

netstat -in:
Name Mtu Network Address Ipkts Opkts
lan2 1500 192.168.2.0 192.168.2.100 25873299 24119824
lan1 1500 192.168.1.0 192.168.1.100 648720484 640936754
lo0 4136 127.0.0.0 127.0.0.1 7816109 7816109

ifconfig lan1
lan1: flags=843
inet 192.168.1.100 netmask ffffff00 broadcast 192.168.1.255
ifconfig lan2
lan2: flags=843
inet 192.168.2.100 netmask ffffff00 broadcast 192.168.1.255

Sandman!
Honored Contributor

Re: about ip_strong_es_model and multiple default gateway

>What I really want is that when the client access 192.168.1.100, the default
>route should be 192.168.1.1 while if the client access 192.168.2.100, the
>default route should be 192.168.2.1, then both layer 4 switch will be working

My bad as I overlooked the fact that you are using Class C addresses with the default netmask i.e. 255.255.255.0. However the ndd tunable for the strong end system model (ip_strong_es_model) works only for packet routing at source (HP server) not destination (the client in the JPEG). Meaning that outbound packets (destined for the client) will use the respective default gateways but not the inbound packets (destined for the server). read more about it here...

http://www.faqs.org/rfcs/rfc1122.html
Xiang Zhao_1
Advisor

Re: about ip_strong_es_model and multiple default gateway

Thanks for the replay. I have read the Strong ES model in the RFC. As you said, "outbound packets (destined for the client) will use the respective default gateways", however, this does't work for me. The default gateway HPUX chosen is random. For example, it stick to 192.168.1.1 when I access the server via switch 1 or switch 2, which means the request via switch2 will fail. What I want is that if the client access the virtual server ip configured in switch 1, the server should choose switch 1 as the default gateway. If the client access the virtual server ip configured in switch 2, the server should choose switch 2 as the default gateway. Is this possible?

Background on layer 4 switching: the client access the virtual ip(internet addr) configured on the switch, the switch will
forward the request to the server via internal network, and expect the server to send the reply packet for further processing before sending back to the client. So if the packet goes through switch 1, but reply packet goes through switch2, the client request will fail.
Xiang Zhao_1
Advisor

Re: about ip_strong_es_model and multiple default gateway

AN IMPORTANT UPDATE:
Since our application is UDP based, I setup a test tcp application. It works! With ip_strong_es_model = 1, I can access the server via switch 1 or switch2. If ip_strong_es_model = 0, only one switch will work.

So ip_strong_es_model may just work with TCP, since UDP is connectionless. However, this need to be confirmed by the experts here.

-Xiang