Controlling Logon Storms

Oracle strongly recommends that you use connection pools. If you must handle many direct connections, then you can tune the maximum number of allowed connections to control logon storms.

Tuning the maximum number of connections requires root access to modify the operating system (OS) connection settings, and database administrator privileges to update the sqlnet.ora file.

Oracle Maximum Availability Architecture (MAA) best practices recommend the following manual tuning on servers that host Global Service Managers:

  1. Increase the listen() syscall backlog at the OS level to increase the maximum number of connections a server application can set. You do this by changing the somaxconn setting to enable syscall to increase the number of connections that can be queued for acceptance on a listening socket (that is, the backlog queue for accept()). For example, you can change the somaxconn value from an existing value (such as 4096) to 8000.

    To apply the new value without restarting the server, run the following command as root:

    echo 8000 > /proc/sys/net/core/somaxconn

    This command redirects the standard output of the echo command to the /proc/sys/net/core/somaxconn, overwriting its current value. Changes made to /proc/sys/net/core/somaxconn are not persistent and will be lost after a restart unless you specifically configure them in system startup scripts or /etc/sysctl.conf.

  2. To keep this value after a system restart, add this line to /etc/sysctl.conf:

    net.core.somaxconn=8000
  3. Increase queuesize for the Global Service Manager listener.

    To increase the queuesize setting, update the sqlnet.ora file in the Oracle home from which the listeners are running. For example, to update the quuesize setting to 8000, edit the file to change the sqlnet.ora entry for TCP.QUEUESIZE:

    TCP.QUEUESIZE=8000

Parent topic: Application Development Considerations