netstat -a hang


 
Thread Tools Search this Thread
Special Forums IP Networking netstat -a hang
# 1  
Old 09-20-2012
netstat -a hang

Hi, on our Solaris 10 servers, one day 'netstat -a' command return very slow after TCP output, wait 5 minute on this line -
SCTP:
Local Address Remote Address Swind Send-Q Rwind Recv-Q StrsI/O State
------------------------------- ------------------------------- ------ ------ ------ ------ ------- -----------

'netstat -na' return in seconds but not 'netstat -a'. Next day the issue disappear, 'netstat -a' return in seconds. SCTP output like this -

SCTP:
Local Address Remote Address Swind Send-Q Rwind Recv-Q StrsI/O State
------------------------------- ------------------------------- ------ ------ ------ ------ ------- -----------
localhost localhost 0 0 102400 0 32/32 CLOSED
Just wondering what could be the reason this command return slow. What was it waiting?

Thanks!
This User Gave Thanks to ora_dba For This Post:
# 2  
Old 09-20-2012
See man netstat to understand what -n does.

It was trying to look up domain names for each and every IP in the list, which if there's a lot can take ages, and if there's DNS trouble will wait until it times out.
# 3  
Old 09-20-2012
So does it mean the connection to DNS server got timeout?

---------- Post updated at 12:06 PM ---------- Previous update was at 12:03 PM ----------

TCP/IP was fine though, only SCTP. The fact that only one days returns 5 minutes, other days in seconds, what area should I ask them to check?
# 4  
Old 09-20-2012
Either timed out, or just too many of them. If there's a thousand different IP's connected, that's a thousand DNS lookups. If you want to automate it, always give -n.

I've also noticed netstat hanging sometimes when there's lots of network connections being constantly made and broken, even given -n. The kernel's just too busy, perhaps. It won't hang forever, but can take some seconds. This is normal enough. If it's a problem, you can kill it and try again...
# 5  
Old 09-20-2012
That day, netstat -a return after wait 5 minutes. Even we kill it and retry. When you said ' look up domain names for each and every IP in the list', where do they look up? from DNS server or local unix server? and where is the list?
# 6  
Old 09-20-2012
It'd just be a normal reverse-DNS lookup, asking a DNS server what domain name has that IP. Where it asks first depends on your configuration.
# 7  
Old 09-21-2012
Quote:
Originally Posted by ora_dba
When you said ' look up domain names for each and every IP in the list', where do they look up? from DNS server or local unix server?
Where to look and in which order is defined in the name service configuration file:
Code:
grep ^hosts /etc/nsswitch.conf

Might be a combination of files (/etc/hosts), dns (/etc/resolv.conf), nis (ypwhich), ldap (ldapclient list), nis+ ...
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Solaris

ALOM hang

Hi guys, I'm new with solaris. I just received sunfire T2000 server. Problem: ALOM keep hang/stuck/jammed. Steps do before it hang : 1. Connect to T2000 (using RJ45 - DB9 cable) 2. Open putty, connect via serial. 3. Power on the server. 4. Its loading. 5. then, hang. ... (1 Reply)
Discussion started by: rajasraf
1 Replies

2. UNIX for Advanced & Expert Users

Help with netstat

Hi, I want to list the time for how long a secure connections last to my server/blade. i am using netstat command to get the same, but not sure how to get the time for how long connections is being ESTABLISHED. netstat -na | grep 'ESTABLISHED' | grep :443 |awk '{print $4}' | cut -d: -f1 |... (1 Reply)
Discussion started by: Siddheshk
1 Replies

3. Solaris

netstat -- what am i looking at?

Greetings to all, Here is a line of output from my netstat command cbp031.904 wdcprodhome.nfsd 98304 0 49640 0 ESTABLISHED The only thing i recognize is the unix machine "cbp031" but what is .904 and all the other data telling me? Thanks in advance. (3 Replies)
Discussion started by: Harleyrci
3 Replies

4. Shell Programming and Scripting

Hang in linux

Hi guys sorry for my English I am from GREECE and I speak from translator.I have in my school work to hang the program I've done is this encounter the problems is that the meter that I have put on the mistakes does not work (I have not stated anywhere lathi = 0, not to reset the meter at each of... (1 Reply)
Discussion started by: soula
1 Replies

5. AIX

Boot from CD hang

Why is one of my blade hanging and does nothing after trying to boot from CD??? ================== I tried to press 1....JS20 does not support SMS menu Here's what I see after 30 minutes... ------------------------------------------------------------------------------- ... (0 Replies)
Discussion started by: mifch
0 Replies

6. Shell Programming and Scripting

Ftp hang

Im making a script that goes out to about 200 servers and grabs log files daily and need to make sure the script gets all the servers it can even if one is out. I am ftp'ing the files over but if i cant connect to the server the process looks like it dies and the script is finished. (4 Replies)
Discussion started by: rcunn87
4 Replies

7. Red Hat

system hang

Hello, I am having a HP proliant 350 G3 sever installed wih RedHat linux 9.0 when I enterd using any user(Except root) the server hanged after few seconds, also the folder icons are blacked out and the names of the folder icons are disapper. can any body help me. Ajay (1 Reply)
Discussion started by: ajay234
1 Replies

8. SuSE

Hang a Process

this may be something trivial to many of you, but is there a way to purposely cause a process to hang? (6 Replies)
Discussion started by: laila63
6 Replies

9. Linux

Help for Linux hang up

Hi everybody, i need help regarding my Linux start up.I was trying to configure internet connection with my Red Hat in order to use for Internet,but of no avail and I think I have changed one parameter to activate device during computer start up. Now the problem is during start up and... (1 Reply)
Discussion started by: andysastre
1 Replies

10. IP Networking

Netstat

Giving netstat command on the prompt gives commands such as localhost.43592 localhost.35237 32768 0 32768 0 TIME_WAIT localhost.43594 localhost.43595 32768 0 32768 0 TIME_WAIT localhost.43598 localhost.35237 32768 0 32768 0 TIME_WAIT... (6 Replies)
Discussion started by: DPAI
6 Replies
Login or Register to Ask a Question