Unable to set open files limit via limits.conf

Solution Verified - Updated -

Issue

  • Unable to raise the open files limit, either via ulimit command or /etc/security/limits.conf file

    # cat /proc/sys/fs/file-max
    5096000
    
    # cat /proc/sys/fs/file-nr
    4448    0       5096000
    
    # grep limit /etc/pam.d/system-auth
    session     required      pam_limits.so
    
    # egrep -v '^$|^#' /etc/security/limits.conf
    Username           hard    nofile          65536
    Username           soft    nofile          32768
    
    # su Username -lc 'ulimit -n'
    2048
    
    # su - Username
    $ ulimit -n
    2048
    
    $ ulimit -n 4096
    -bash: ulimit: open files: cannot modify limit: Operation not permitted
    

Environment

  • Red Hat Enterprise Linux 6

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In
Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.