Results 1 to 7 of 7

Thread: how to increase ldap max open files ?

  1. #1

    Default how to increase ldap max open files ?

    Hi,

    I would like to increase max open files for ldap from 1024 to 4096 or more

    How do I do that with openSuse ?

    Previously I did that with Mandriva, edit /etc/sysconfig/ldap and uncomment MAXFILES=4096, but this is not working with openSuse.

    Any idea how to increase MAXFILES for openldap in openSuse ?

    Thanks.

  2. #2
    Join Date
    Jun 2008
    Location
    Podunk
    Posts
    27,124
    Blog Entries
    15

    Default Re: how to increase ldap max open files ?

    Hi
    What does the output from;
    Code:
    ulimit -n
    cat /proc/sys/fs/file-max
    cat /proc/`pidof slapd`/limits
    I think if ulimit isn't set to 4096, that's possibly why.
    Cheers Malcolm °¿° SUSE Knowledge Partner (Linux Counter #276890)
    SUSE SLE, openSUSE Leap/Tumbleweed (x86_64) | GNOME DE
    If you find this post helpful and are logged into the web interface,
    please show your appreciation and click on the star below... Thanks!

  3. #3

    Default Re: how to increase ldap max open files ?

    Code:
    spare:~ # ulimit -n
    1024
    Code:
    spare:~ # cat /proc/sys/fs/file-max
    47358
    Code:
    spare:~ # cat /proc/`pidof slapd`/limits
    Limit                     Soft Limit           Hard Limit           Units
    Max cpu time              unlimited            unlimited            seconds
    Max file size             unlimited            unlimited            bytes
    Max data size             unlimited            unlimited            bytes
    Max stack size            8388608              unlimited            bytes
    Max core file size        0                    unlimited            bytes
    Max resident set          unlimited            unlimited            bytes
    Max processes             3726                 3726                 processes
    Max open files            1024                 4096                 files
    Max locked memory         65536                65536                bytes
    Max address space         unlimited            unlimited            bytes
    Max file locks            unlimited            unlimited            locks
    Max pending signals       3726                 3726                 signals
    Max msgqueue size         819200               819200               bytes
    Max nice priority         0                    0
    Max realtime priority     0                    0
    Max realtime timeout      unlimited            unlimited            us
    which file should i edit to increase it ?

    thanks.

  4. #4
    Join Date
    Jun 2008
    Location
    Podunk
    Posts
    27,124
    Blog Entries
    15

    Default Re: how to increase ldap max open files ?

    On Mon 24 Nov 2014 03:06:16 AM CST, jiunnyik wrote:
    Code:
    spare:~ # ulimit -n
    1024
    <snip>

    which file should i edit to increase it ?

    thanks.
    Hi
    The way I understand it is it's a soft limit, so should be able to
    change via;
    Code:
    ulimit -n 4096
    ulimit -a
    You may have to configure it specifically with pam and limits.conf
    for ldap (see man limits.conf)? I'm not an ldap user (except for
    defaults), maybe other can help....

    --
    Cheers Malcolm °¿° LFCS, SUSE Knowledge Partner (Linux Counter #276890)
    SUSE Linux Enterprise Desktop 12 GNOME 3.10.1 Kernel 3.12.28-4-default
    If you find this post helpful and are logged into the web interface,
    please show your appreciation and click on the star below... Thanks!


  5. #5

    Default Re: how to increase ldap max open files ?

    i edit /etc/security/limits.conf, add in

    Code:
    ldap            soft    nofile          4096
    and I run "cat /proc/`pidof slapd`/limits" as root

    Code:
    spare:~ # cat /proc/`pidof slapd`/limits
    Limit                     Soft Limit           Hard Limit           Units
    Max cpu time              unlimited            unlimited            seconds
    Max file size             unlimited            unlimited            bytes
    Max data size             unlimited            unlimited            bytes
    Max stack size            8388608              unlimited            bytes
    Max core file size        0                    unlimited            bytes
    Max resident set          unlimited            unlimited            bytes
    Max processes             3726                 3726                 processes
    Max open files            1024                 4096                 files
    Max locked memory         65536                65536                bytes
    Max address space         unlimited            unlimited            bytes
    Max file locks            unlimited            unlimited            locks
    Max pending signals       3726                 3726                 signals
    Max msgqueue size         819200               819200               bytes
    Max nice priority         0                    0
    Max realtime priority     0                    0
    Max realtime timeout      unlimited            unlimited            us
    but when i run ulimt -a as ldap user, i get
    Code:
    ldap@spare:~> ulimit -a
    core file size          (blocks, -c) 0
    data seg size           (kbytes, -d) unlimited
    scheduling priority             (-e) 0
    file size               (blocks, -f) unlimited
    pending signals                 (-i) 3726
    max locked memory       (kbytes, -l) 64
    max memory size         (kbytes, -m) unlimited
    open files                      (-n) 4096
    pipe size            (512 bytes, -p) 8
    POSIX message queues     (bytes, -q) 819200
    real-time priority              (-r) 0
    stack size              (kbytes, -s) 8192
    cpu time               (seconds, -t) unlimited
    max user processes              (-u) 3726
    virtual memory          (kbytes, -v) unlimited
    file locks                      (-x) unlimited
    the openfiles are different.

  6. #6
    Join Date
    May 2012
    Location
    Finland
    Posts
    2,005

    Default Re: how to increase ldap max open files ?

    If you want the service to have more file handles, you need to edit the systemd file; /usr/lib/systemd/system/slapd.service

    Add;
    LimitNOFILE=32768

    Under [Service], then issue systemctl daemon-reload and systemctl restart slapd. Ran into the same issue when tuning Varnish for tens of thousands of simultaneous connections :-)
    .: miuku #suse @ irc.freenode.net
    :: miuku@opensuse.org

    .: h​ttps://download.opensuse.org/repositories/home:/Miuku/

  7. #7

    Default Re: how to increase ldap max open files ?

    Quote Originally Posted by Miuku View Post
    If you want the service to have more file handles, you need to edit the systemd file; /usr/lib/systemd/system/slapd.service

    Add;
    LimitNOFILE=32768

    Under [Service], then issue systemctl daemon-reload and systemctl restart slapd. Ran into the same issue when tuning Varnish for tens of thousands of simultaneous connections :-)

    Miuku,

    no slapd.service in /usr/lib/systemd/system

    im running opensuse 13.1

    thanks.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •