Este contenido no está disponible en el idioma seleccionado.
19.4. Verifying Kernel Parameters
To see all kernel parameters, execute:
su - root sysctl -a
For Oracle 10g, the following kernel parameters have to be set to values greater than or equal to the recommended values which can be changed in the
proc
file system:
To verify
shmmax
, execute:
cat /proc/sys/kernel/shmmax shmmax = 2147483648
To verify
shmmni
, execute:
cat /proc/sys/kernel/shmmni shmmni = 4096
To verify the
shmall
parameter, execute the command below. shmall
is used in 10g R1.
cat /proc/sys/kernel/shmall shmall = 2097152
To verify shmmin, execute:
ipcs -lm |grep "min seg size" shmmin = 1
Note that
shmseg
is hardcoded in the kernel, the default is much higher.
shmseg = 10
To verify
semmsl
, execute:
cat /proc/sys/kernel/sem | awk '{print $1}' semmsl = 250
To verify
semmns
, execute:
cat /proc/sys/kernel/sem | awk '{print $2}' semmns = 32000
To verify
semopm
, execute:
cat /proc/sys/kernel/sem | awk '{print $3}' semopm = 100
To verify
semmni
, execute:
cat /proc/sys/kernel/sem | awk '{print $4}' semmni = 128
To verify
file-max
, execute:
cat /proc/sys/fs/file-max file-max = 65536
To verify
ip_local_port_range
, execute:
cat /proc/sys/net/ipv4/ip_local_port_range ip_local_port_range = 1024 65000
Note
Do not change the value of any kernel parameter on a system where it is already higher than listed as minimum requirement.
On the following versions of Red Hat Enterprise Linux 4 x86, 3 U5 x86, 3 U5 x86-64, and 2.1; you may have to increase the kernel parameters
shmmax
, semopm
, and filemax
to meet the minimum requirement. On Red Hat Enterprise Linux 4 x86-64 you may have to increase shmmax
and semopm
.
Oracle also recommends to set the local port range
ip_local_port_range
for outgoing messages to "1024 65000" which is needed for high usage systems. This kernel parameter defines the local port range for TCP and UDP traffic to choose from.
In order to meet these requirements, you may have to add the following lines to the
/etc/sysctl.conf
file which are read during the boot process:
kernel.shmmax=2147483648 kernel.sem=250 32000 100 128 fs.file-max=65536 net.ipv4.ip_local_port_range=1024 65000
Adding these lines to the
/etc/sysctl.conf
file will cause the system to change these kernel parameters after each boot using the /etc/rc.d/rc.sysinit
script which is invoked by /etc/inittab
. But in order that these new added lines or settings in /etc/sysctl.conf
become effective immediately, execute the following command:
su - root sysctl -p
For more information on shmmax, shmmni, shmmin, shmseg, and shmall, see Chapter 7, Setting Shared Memory. For more information on semmsl, semmni, semmns, and semopm, see Chapter 24, Creating Oracle Directories. For more information on filemax, see Chapter 9, Setting File Handles.
Starting with 10g R2 some network settings must be adjusted as well which is checked by OUI. Oracle recommends the default and maximum send buffer size (
SO_SNDBUF
socket option) and receive buffer size (SO_RCVBUF
socket option) to be set to 256 KB. The receive buffers are used by TCP and UDP to hold the received data for the application until it is read. This buffer cannot overflow because the sending party is not allowed to send data beyond the buffer size window. This means that datagrams will be discarded if they do not fit in the receive buffer. This could cause the sender to overwhelm the receiver.
The default and maximum window size can be changed in the proc file system without reboot by running the following commands: The default setting in bytes of the socket receive buffer.
# sysctl -w net.core.rmem_default=262144
The default setting in bytes of the socket send buffer.
# sysctl -w net.core.wmem_default=262144
The maximum socket receive buffer size which may be set by using the SO_RCVBUF socket option.
# sysctl -w net.core.rmem_max=262144
The maximum socket send buffer size which may be set by using the SO_SNDBUF socket option.
# sysctl -w net.core.wmem_max=262144
To make the change permanent, add the following lines to the
/etc/sysctl.conf
file, which is used during the boot process:
net.core.rmem_default=262144 net.core.wmem_default=262144 net.core.rmem_max=262144 net.core.wmem_max=262144