Operating System - HP-UX
1823376 Members
2513 Online
109654 Solutions
New Discussion юеВ

Re: output order of netstat -in

 
SOLVED
Go to solution
Mad_1
Regular Advisor

output order of netstat -in

Dear all

I recently installed a HP-UX 11.0 (with multiple LAN cards running in MC/SG). I found that the output of "netstat -in" is totally different from the output in HP-UX 10.20.

The output is attached for your reference.

In HP-UX 10.20, the output of netstat is in order, lo0 first, then lan0 (the real IP), then lan0 (the cluster IP), then lan1,.....

But in HP-UX11.0, the output of netstat is a mess, no order at all.

The /etc/rc.config.d/netconf are configured similar in both cases. Is there any other configuration I should set in HP-UX11.0 to get an order output?

Thanks
10 REPLIES 10
T G Manikandan
Honored Contributor

Re: output order of netstat -in

What patch bundles are on the system?

Do you have the PHNE_17434 netstat patch?



Mad_1
Regular Advisor

Re: output order of netstat -in

Yes, this patch is already installed in the HP-UX11.0.
Rajeev  Shukla
Honored Contributor

Re: output order of netstat -in

There are some changes in 11.00 network with respect to 10.20.
See in 10.20 if you added any package or created a virtual interface(assign an IP to a package) you'll have it always as that interface name. i.e why you have more lan0. You output of 10.20 explains you have 3 interface lan2 is standby lan1 has a Ip and lan0 and other are packages bound to lan0.
Now in 11.00 when you create a virtual interface using ifconfig or assign IP to a package it create a new virtual name like lan0:1 and so on. So your output of 11.00 explains you have 4 interfaces. With 3 IP to lan0, lan1, lan2 and lan3 a standby interface. lan0:1 & lan0:2 are 2 packages in guess (virtual IP assigned to package). So i dont feel there is a mess in output of netstat -in. Just you need to understand.

Cheers
rajeev
Rajeev  Shukla
Honored Contributor

Re: output order of netstat -in

Hi,
I dont see any thing messed, this is the way the output of 11.00 is.
Let me know what you feel is messy.

Rajeev
Mad_1
Regular Advisor

Re: output order of netstat -in

Is there any implication on the lan order with the netstat output?

e.g using which lan as the source IP for ping or snmpwalk?
Rajeev  Shukla
Honored Contributor

Re: output order of netstat -in

You can use either lan for pinging virtual or static.

rick jones
Honored Contributor
Solution

Re: output order of netstat -in

Don't read anything into the order in which interfaces appear in netstat -in output. (nor should anything like scripts etc rely on it) Any relationship there between order in netstat -in and route selection should be considered a coincidence.

Outbound interface is selected based on routes (netstat -rn). The most complete match for the destination IP will be the route used (host route, then (sub)net route, then default).

Now, if you ifconfig multiple interfaces into the same IP subnet, the order of _ifconfig_ will determine which is used for outbound traffic. However, such configurations, while possible, and even "supported" are not something one should do without strong knowledge of routing, and the effects of ndd settings like ip_strong_es_model. (ftp://ftp.cup.hp.com/dist/networking/briefs/annotated_ndd.txt)

there is no rest for the wicked yet the virtuous have no pillows
Mad_1
Regular Advisor

Re: output order of netstat -in

Thanks Rick.

Actually, what you said is my concern.

Because I have several interfaces configured within the same subnet, when I tried to execute "snmpwalk" to a specific node, I found that there must be some failure and some succeed.

I suspect that the snmpwalk use different outbound interfaces each time. Because each specific node is configure SNMP access control, only specific IP can SNMP query to those nodes.

I would like to know that any method to configure the snmpwalk (and other snmp command) to use fixed outbound interface.

Thank
rick jones
Honored Contributor

Re: output order of netstat -in

Multiple NICs configured into the same subnet is an "interesting" area. Basically, the system will receive traffic on all N NIC's configured into the subnet, but will send replies out only one of the N interfaces - either the first or last one ifconfig'd - I can never remember.

The _best_ way to put multiple NICs into the same subnet (particularly if HA is a concern) is to use Auto Port Aggregation, and bind the N NICs into an aggregate. Then ifconfig the IPs to the aggregate and away you go.

Otherwise, you need to start doing creative things with ndd to set ip_strong_es_model and/or explicit host routes pointing at explicit local IPs. ftp://ftp.cup.hp.com/dist/networking/briefs/annotated_ndd.txt
there is no rest for the wicked yet the virtuous have no pillows
??_29
Advisor

Re: output order of netstat -in

Hi
I see your attachment.I think that
lan0 is configured 3 IP address.
Lan2 is your dedicative heardbeat IP.
Lan3 is your standby NIC.So it isn't configured IP address.Your lan0 and lan1 are in the same subnet.I don't know your application ,so I cann't tell you which is your fixed IP and which is your floating IP.
Best regards.
Weit