Bug 14173

Summary: bind(2) sets errno to undocumented EAGAIN
Product: Documentation Reporter: crandall <crandall>
Component: Books & ArticlesAssignee: freebsd-doc (Nobody) <doc>
Status: Closed FIXED    
Severity: Affects Only Me    
Priority: Normal    
Version: Latest   
Hardware: Any   
OS: Any   

Description crandall 1999-10-07 05:20:01 UTC
Under high load, bind() fails with a -1 and sets errno to EAGAIN.
This is not documented in the bind(2) manual page under the ERRORS
section.

Using ktrace/kdump,

   522 http_load CALL  socket(0x2,0x1,0x6)
   522 http_load RET   socket 4
   522 http_load CALL  bind(0x4,0x805f404,0x10)
   522 http_load RET   bind -1 errno 35 Resource temporarily unavailable

Fix: 

Add EAGAIN to the ERRORS section of the bind(2) manual page with
a description of which resources are exhausted.
How-To-Repeat: Use http_load from http://www.acme.com/software/http_load to
stress the system by testing a local HTTP server (run http_load
and the HTTP server on the same machine).
Comment 1 kbyanc 1999-10-08 15:23:20 UTC
  From the same discussion on -hackers, I submitted the docs/14181 PR (I
must had missed that you had already sent one in). It includes a suggested
patch (real simple) that simply states "Kernel resources to complete the
request are temporarily unavailable".
  For the committer who takes care of this PR, please close that PR also.
(Sorry again for the redundancy).

  Thanks,

  Kelly
 ~kbyanc@posi.net~
  FreeBSD - The Power To Serve - http://www.freebsd.org/
  Join Team FreeBSD - http://www.posi.net/freebsd/Team-FreeBSD/
Comment 2 nik freebsd_committer freebsd_triage 1999-11-01 19:42:37 UTC
State Changed
From-To: open->closed

The man page has been fixed.  Thanks.