Next | Prev | Up | Top | Contents | Index

unpdg_sendspace

Description

This parameter controls the size of a data-gram that can be sent over a socket.

Value

Default: 0x2000 (8 KB)

When to Change


Data-gram sockets operate slightly differently from streams sockets. When a streams socket fills the receive buffer, all data is then sent to the send buffer, and when the send buffer fills up, an error message is issued. Data-gram sockets allow data-grams to fill the receive buffer, and when the receive buffer is full, all future data-grams are discarded, and the error EWOULDBLOCK is generated. Therefore, the unpdg_sendspace parameter serves only to limit the size of a data-gram to not more than can be received by the receive buffer.

Note that the default data-gram socket receive buffers are twice the size of the default data-gram send buffers, thus allowing the process to appear the same as the streams sockets.

It is generally recommended that you not change the size of this parameter without also changing the default receive buffer size for data-gram sockets. If you raise the value of this parameter (unpdg_sendspace) without raising the receive buffer size (unpdg_recvspace), you will allow the sending half of the socket to send more data than can be received by the receiving half. Also it is generally recommended that socket buffer sizes be set individually via the setsockopt(2) system call. See the setsockopt(2) reference page for more information on setting specific individual socket options.


Next | Prev | Up | Top | Contents | Index