The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Dummies Questions & Answers
.
google unix.com



UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !!

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Build a Google Talk Client Using Oracle ADF Faces Rich Client and the Active Data Ser iBot Oracle Updates (RSS) 0 04-18-2008 06:10 PM
socket programming : client server IPC abc.working UNIX for Dummies Questions & Answers 3 10-17-2007 04:25 AM
UDP socket - can both client and server recv and send rvan High Level Programming 1 05-09-2007 02:36 AM
client socket read returns 0 bytes axes High Level Programming 1 11-22-2006 08:04 AM
OopenSSH not letting me in! BG_JrAdmin SUN Solaris 2 09-12-2006 11:54 AM

Closed Thread
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish Powered by Powered by Google
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
  #1 (permalink)  
Old 02-20-2004
fusion99 fusion99 is offline
Registered User
  
 

Join Date: Jan 2004
Posts: 7
client app not letting go of socket

Ok here's the situation

We have an application that our users log into over the network to one of our unix boxes (Solaris 8). I had this situation occur the other day where an user claimed that he totally shutdown the app because it froze up and wasn't able to log back in.

I performed a netstat on the port and I could see that he wasn't getting back in because the original connection (frozen app) was still established and I could see time_waits for the new attempts to login (the time_waits are because we're not allowing the user to log back in because technically he's still logged in).

after a while I saw the ESTABLISHED switch to FIN_WAIT_2, I never seen this state before (can someone explain what it means in laymens terms and give an example of a situation it might occur).

Anyway the user wanted an explanation and I have never seen this before, usually when a user closes the app the connection will drop but this time it stayed established. Is it possible that the session level processes were still running on the Windows 2000 server pc he was using?? even though everything on the desktop said the app was closed??

Anyway, I would greatly appreciate any info you could spare on this situation and also is there a website or reference somewhere that could explain real life situations where certain netstat states would occur??

thanks in advance
  #2 (permalink)  
Old 02-20-2004
Perderabo's Avatar
Perderabo Perderabo is offline Forum Staff  
Unix Daemon
  
 

Join Date: Aug 2001
Location: Ashburn, Virginia
Posts: 9,111
The local program did a shutdown() or a close() on the socket in question. This sent a FIN packet to the remote system and put the socket in FIN_WAIT_1. The remote system ACKED the FIN packet and the local system got the ACK. That moved the socket to FIN_WAIT_2.

The idea is that at some point the remote system will close() or shutdown() its side on the socket. When that happens, the remote system will send a FIN. The local system will then ACK that FIN and move the socket to TIME_WAIT.

But if the remote system had a hung program, the remote system's kernel will still ACK the first FIN. Then if the remote system is rebooted, things will hang forever.

FIN_STATE_2 happens a lot when the remote systems are pc's. You must not run netstat very much.
Closed Thread

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT -4. The time now is 05:36 AM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language Translations Powered by .
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0