Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3227760
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 17, 20262026-05-17T16:36:45+00:00 2026-05-17T16:36:45+00:00

As far as my understanding goes, once we complete the ‘listen’ call with bound

  • 0

As far as my understanding goes, once we complete the ‘listen’ call with bound socket, all the TCP connections initiated by the client starts succeeding, but, when the accept is called, there is a good amount of possibility that the accept call might fail (due unavailable memory or file descriptors crossing the limit etc).

I ran some simple tests in solaris.

Server:
1. Reduce the max number of file descriptors to 8 using the ulimit command

  1. Set the backlog in listen to 8.

  2. Do a listen.

  3. Call accept in a loop for 8 times and then go to sleep

Client:

  1. Connect around 8 connections.

  2. Go to sleep

Test Result:

On the Client side all connections pass.
On the Server Side, accept passes only for 4, and fails for 4. (This is reasonable, considering the fact that 3 file descriptors are for standard, one for listen and then there is space only for 4 more connections). But, the netstat shows all 8 connections as established.

TCP Dump, shows 3-way handshake has succeeded for all 8 connections. When will the server notify the 4 connections on the client that they have failed? (i.e. when will it send a FIN to them?)

I noticed another behaviour also, once the server goes to sleep and then if I kill process by doing a CTRL+C, then I find that the FIN is being sent for those 4 failed connections.

I am a little confused about the behaviour. Any help is very much appreciated.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-17T16:36:46+00:00Added an answer on May 17, 2026 at 4:36 pm

    From what you describe, my guess is that the OS has indeed established all 8 connections and will buffer any data that the client sends (up to the window size). Once your server frees up some FDs and is able to accept the pending connections, you should be able to read whatever has been sent until then. That would also explain why the connections are terminated when your process is killed.

    In short: the connections really are there, but your program can’t use them because it has no free FDs.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

As far as my understanding goes Modules kann be used to split an Application
In mySql, as far as my understanding goes, its possible for us to grant
Could someone clear something up for me? As far as my understanding goes, the
As far as my understanding after reading and researching, the purpose of using salt
I've come os far as to gaining basic understanding of prepared statements and I
I'm trying to get a better understanding than I've been able to so far...it's
As far as my understanding, there is no public API available in iPhone SDK
My understanding as far as data frame in R is that it has to
This one is a bit tedious in as far as explaining, so here goes.
I am trying to get a better understanding of CRTP. So far my understanding

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.