Open System Services System Calls Reference Manual (G06.25+, H06.03+)
setsockopt(2) OSS System Calls Reference Manual
SO_KEEPALIVE
Specifies whether to keep connections active by enabling the
periodic transmission of messages on a connected socket. The
default value used when the socket is created is 0 (zero), which
indicates that no periodic messages are sent.
This option is valid only for AF_INET or AF_INET6 sockets.
If this option is specified for sockets of other types, the function
call fails and sets errno to [ENOPROTOOPT].
option_value takes an int value. Specifying any nonzero value
causes periodic transmission of messages.
SO_LINGER Controls whether the system attempts to deliver unsent data that
is queued when a call to the close() function occurs.
This option is valid only for AF_INET or AF_INET6 sockets.
If this option is specified for sockets of other types, the function
call fails and errno is set to [ENOPROTOOPT].
option_value takes a struct linger value, as defined in the
sys/socket.h header file. However, regardless of the option
value, SO_LINGER is always enabled.
SO_OOBINLINE
Specifies whether received out-of-band data (data marked
urgent) is queued with other data. The default value used for the
option when the socket is created is 0 (zero), which indicates
that urgent data is delivered separately.
This option is valid only for AF_INET or AF_INET6 sockets.
If this option is specified for sockets of other types, the function
call fails and sets errno to [ENOPROTOOPT].
option_value takes an int value. Specifying any nonzero value
causes out-of-band data to remain queued with other data.
SO_RCVBUF Sets the receive buffer size in bytes. The default value used for
the option when the socket is created is 8K bytes.
This option is valid only for AF_INET or AF_INET6 sockets.
If this option is specified for sockets of other types, the function
call fails and errno is set to [ENOPROTOOPT].
option_value takes an int value. Specifying a 0 (zero) value, a
negative value, or a value greater than 262144 causes the func-
tion call to fail with errno set to [EINVAL].
SO_REUSEADDR
Specifies whether the rules used in validating addresses supplied
by a bind( ) function call should allow reuse of local addresses.
The default value used for the option when the socket is created
is 0 (zero), which indicates that addresses should not be reused.
option_value takes an int value. Specifying a nonzero value
permits addresses to be reused.
7−40 Hewlett-Packard Company 527186-003