What does errno 99 (EADDRNOTAVAIL) mean?

 
Could be also:
ConstantTypeOS
ENOSTRerrnoMac
ENOPROTOOPTerrnoSolaris
SECURITY1_INITIALIZATION_FAILEDBugCheck CodeWindows
Previous Next
EPROTOTYPE ENOSTR

EADDRNOTAVAIL

EADDRNOTAVAIL concerns the local side of a socket. A program has asked to bind or use an address that the host cannot assign in its current network context. Common examples are binding to an IP address that is no longer configured, using a container address from the host namespace, or selecting IPv4 versus IPv6 incorrectly.

This is different from EHOSTUNREACH and ENETUNREACH. Those describe reachability to a destination; EADDRNOTAVAIL occurs before the application has a valid local endpoint for the requested operation. On systems that choose an ephemeral source port automatically, resource exhaustion in the available port range can also surface during connection setup, so capture the syscall and local address selection path.

What to check

  • Compare the address passed to bind() with addresses actually assigned to the target interface and namespace.
  • Confirm whether DNS or configuration selected an IPv6 address while the socket was created for IPv4, or the reverse.
  • For services bound to a specific address, handle interface renumbering and startup order rather than assuming the address is always present.
  • For high-rate clients, inspect ephemeral-port allocation and connection lifetime.

POSIX bind() · Linux IP socket addressing · FreeBSD connect() errors


Looking for a different code? Search another status or error code.