What does Windows error code 1234 (ERROR_PORT_UNREACHABLE) mean?

 
Previous Next
ERROR_PROTOCOL_UNREACHABLE ERROR_REQUEST_ABORTED

ERROR_PORT_UNREACHABLE

ERROR_PORT_UNREACHABLE points to the destination transport endpoint rather than the route to the host. The host may be reachable, yet no service is accepting traffic for the addressed port and protocol.

UDP and ICMP are a common case

IPv4 ICMP defines destination-unreachable code 3 for a port that is unreachable. Winsock documents a related behavior for UDP: an earlier send can cause a later socket operation to report a reset after an ICMP Port Unreachable message is received. The exact API-level code therefore depends on the path through which the network error is surfaced.

What to verify

  • Destination IP, address family, transport protocol, and port.
  • Whether the service is bound to the expected interface and protocol.
  • ICMP/ICMPv6 errors and their quoted original packet.
  • NAT or load-balancer translation of the destination port.
  • Firewall policy that rejects versus silently drops traffic.

Do not merge this with ERROR_HOST_UNREACHABLE. A port-unreachable signal can prove that the host processed the packet far enough to reject the destination endpoint.

Microsoft: system error codes · IETF: ICMP port unreachable · Microsoft: WSASendTo UDP error behavior


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