Database Reference
In-Depth Information
Note
the non-tCp related parameters are discussed in detail in Chapter 14.
Workshop
In the previous section, we discussed the buffer size of the application to request higher volumes of data. The buffer
sizes are controlled using various parameters. At the O/S level, the network buffer sizes are driven by TCP parameter
and the transport unit sizes.
Step 1
As part of the RAP testing discussed in Chapters 3 thru 5, we discussed that while tuning the servers for scalability, the
network-related parameters needed to be verified and tuned if possible. The common buffer-related parameters and
default values required to configure Oracle Database 11g Release 2 RAC on Linux are the following:
net.ipv4.tcp_rmem=4096 4194304 4194304
net.ipv4.tcp_wmem=98304 4194304 4194304
net.ipv4.tcp_window_scaling=1
The tcp_rmem is used to set the amount of memory reserved for TCP receive buffers. The first value 4096 of the
parameter tcp_rmem just shown is the minimum receive buffer for each TCP connection; and this buffer is always
allocated to a TCP socket, even when there is a high demand on the system. The second value specified tells the kernel
the default receive buffer allocated for each TCP socket. The third value specifies the maximum receive buffer that can
be allocated for a TCP socket.
The tcp_wmem is used to set the amount of memory reserved for TCP send buffers. Similar to the receive buffer,
this variable also takes three different values, which hold information on how much TCP send buffer memory space
each TCP socket has to use. The first value in this variable tells the minimum TCP send buffer space available for a
single TCP socket. The second value in the variable tells us the default buffer space allowed for a single TCP socket to
use. The third value tells the kernel the maximum TCP send buffer.
Step 2
Oracle relies on the volume of data that each Oracle session can transmit, called the session data unit (SDU). Prior to
Oracle Database Version 11g, the SDU defaulted to 2K; the new default value is 8K. Because the Oracle database block
size in typical applications defaults to 8K, this size is sufficient in most cases. However, when larger volumes of data
are being handled between two destinations—for instance, in the case of a dataguard implementation, when redo
data is sent from the primary database to the standby database—higher SDU sizes of up to 32K are recommended.
Every time a packet or buffer of data is transmitted to a destination, if the buffer size is not sufficiently large
enough to hold this data, the packet is broken down into smaller sizes. This means it could take several round-
trips for the enter packet/buffer to reach the destination. Apart from the multiple network trips to complete the
transmission, every time a packet reaches a destination, TCP needs to send an ACK (acknowledgment) signal back to
the sender. Increasing the SDU size would reduce the number of round-trips and the number of ACKs that need to be
transmitted.
To get the best results from setting the SDU sizes, the values should be set for both the client and the database
server, for example, to increase the size from 8K to 16K.
 
 
Search WWH ::




Custom Search