1 Reply Latest reply: Aug 13, 2012 4:55 PM by 802907 RSS

    cn=monitor "readwaiters"

    833384
      While troubleshooting a plugin issue it was suggested to start running this script:
      Re: ns-slapd process is using 99% CPU.

      I've been running the script for about a week now, and I am seeing occasional spikes in the "readwaiters" & "pending operations", I'm assuming that the two numbers are related based on what I understand of them, so I'm focusting on the readwaiters for now.

      Looking over the doc it describes a readwaiter as "Number of connections where some requests are pending and not currently being serviced by a thread in Directory Server."

      So in terms of performance monitoring what exactly does this mean? Does this mean that the directory server is too busy and unable to handle the amount of requests coming in? or is this that there is a wait on the client side and the DS is waiting for communication to come back from the client before proceeding?

      We have two servers in our prod environment, I'm running the script above on both servers every minute. On ServerA I am not seeing any readwaiters or pendingoperations at any time during the day. On ServerB I am seeing these two numbers jump from 0/1 up to 10/12 during one of the monitor checks and then dropping back down to 0/1 at the next check. This happens a few times a day, and appears as though it might be slowing down performance on the server.

      The only difference I am seeing between the servers (and this is a misconfiguration that I need to fix) is that ServerA has a Max Threads of 30 & ServerB has a Max Threads of 50.

      Neither server has high CPU usage (slapd averages about 7%), and both have 300-500MB free RAM. Both servers are 12 core with 8 (ServerB) & 10 (ServerA) GB RAM.

      My first thought would be that I need to drop the Max Threads on ServerB down to 30.
        • 1. Re: cn=monitor "readwaiters"
          802907
          Readwaiters is most closely related to the request queue backlog.

          When a request is accepted by the Directory server, it is enqueued in the request queue. Then, as worker threads become available to service requests, the enqueued requests are dequeued by worker threads for processing. The request queue backlog is simply the number of requests in the queue, while readwaiters is the number of connections associated with one or more requests currently backlogged in the queue.

          The combination will tell you, if your backlog is high, whether the enqueued requests are associated with more or fewer connected clients. In the case where you have set max threads per conn to something like 5, some requests may be backlogged due to your resource limits. Usually it's because the server is busy. It's possible that you need to make more threads available by increasing the threadnumber on the server configuration, but in my experience this has rarely helped. It's more likely that ACI processing or resource contention is causing the backlog.