How to increase the maximum file open limit when receiving a "Too many open files" error in API Gateway.

Document ID : KB000042893
Last Modified Date : 28/05/2018
Show Technical Document Details
Issue:

Receiving a "Too many open files" error in API Gateway log. Transactions may fail to process during this event.

Environment:
Applies to all versions of API Gateway.
Cause:
The current maximum file open limit has been reached in the system.
Resolution:

To address the "Too many open files" errors, the following steps should be completed:

  1. A file should exist called 99-ssg-appliance.conf inside of /etc/security/limits.d/
  2. Ensure the contents of that file are as follows:
    # Layer 7 Limits (SSG-8322)
    # gateway user value based on /proc/sys/kernel/pid_max
    *               hard    maxlogins    10
    *               hard    core    0
    *               soft    nproc   5120
    *               hard    nproc   16384
    *               soft    nofile  4096
    *               hard    nofile  63536
    gateway         soft    nproc   31768
    gateway         hard    nproc   31768
    # End Layer 7 Limits
  3. Restart the entire node (not just the SSG service) after the new file has been created or updated with the values from step 2 above. This file is only read during the operating system (RHEL) startup process.
Additional Information:
If Keep-Alive is used, then KB000076808 may help you to diagnose the root cause of these errors.