IP_BIND_ADDRESS_NO_PORT(2const) IP_BIND_ADDRESS_NO_PORT(2const) NAME IP_BIND_ADDRESS_NO_PORT - don't reserve an ephemeral port LIBRARY Standard C library (libc, -lc) SYNOPSIS #include /* Definition of IP* constants */ #include int setsockopt(int sockfd, IPPROTO_IP, IP_BIND_ADDRESS_NO_PORT, const int *enable, sizeof(int)); DESCRIPTION Inform the kernel to not reserve an ephemeral port when using bind(2) with a port number of 0. The port will later be automatically chosen at connect(2) time, in a way that allows sharing a source port as long as the 4-tuple is unique. ERRORS See IPPROTO_IP(2const). See setsockopt(2). See ip(7). HISTORY Linux 4.2. SEE ALSO IPPROTO_IP(2const), setsockopt(2), ip(7) Linux man-pages 6.17 2025-11-25 IP_BIND_ADDRESS_NO_PORT(2const)