[prev in list] [next in list] [prev in thread] [next in thread] 

List:       perl-ldap-dev
Subject:    Re: how often to bind and unbind to ldap
From:       Doug Wegscheid <dwegscheid () sbcglobal ! net>
Date:       2014-07-23 12:11:30
Message-ID: 1406117490.61792.YahooMailNeo () web181401 ! mail ! ne1 ! yahoo ! com
[Download RAW message or body]

it depends on how often you are doing the searches.

I have one (vendor-written) application that occasionally decides to do a half \
million queries over 36 hours. It does a separate bind and unbind for each, and as \
the LDAP system administrator, I really wish it would bind once then do the queries.

I also have applications that make connections and do not use them for hours on end. \
They tie up resources, and the dead-connection monitor on our load balancer and on \
the LDAP server tend to kill the connections when not in use that long.

If it's going less often than between every 15-60s, then I'd set up and tear down for \
every batch of searches...



On Wednesday, July 23, 2014 4:22 AM, Daniel Castro <evil.dani@gmail.com> wrote:
 


Hello Guys,

I wrote a script that runs as a system process. If I do constant searches on the LDAP \
server how often should I bind and unbind from the server.

Should I do only one and maintain it. But what about if it disconnects due to \
inactivity during the night. Can I simply bind again on the same object?

Or should I bind, then search, then unbind each time?

Advice?

Thanks,

-- 
+-=====---------------------------+
> +---------------------------------+ | This space intentionally blank for \
> notetaking.
> > > Daniel Castro,                | 
> > > Consultant/Programmer.|
> > > U Andes                         |
+-------------------------------------+


[Attachment #3 (text/html)]

<html><body><div style="color:#000; background-color:#fff; \
font-family:HelveticaNeue-Light, Helvetica Neue Light, Helvetica Neue, Helvetica, \
Arial, Lucida Grande, sans-serif;font-size:10pt"><div><span>it depends on how often \
you are doing the searches.</span></div><div style="color: rgb(0, 0, 0); font-size: \
13.3333px; font-family: HelveticaNeue-Light,Helvetica Neue Light,Helvetica \
Neue,Helvetica,Arial,Lucida Grande,sans-serif; background-color: transparent; \
font-style: normal;"><br><span></span></div><div style="color: rgb(0, 0, 0); \
font-size: 13.3333px; font-family: HelveticaNeue-Light,Helvetica Neue Light,Helvetica \
Neue,Helvetica,Arial,Lucida Grande,sans-serif; background-color: transparent; \
font-style: normal;"><span>I have one (vendor-written) application that occasionally \
decides to do a half million queries over 36 hours. It does a separate bind and \
unbind for each, and as the LDAP system administrator, I really wish it would bind \
once then do the  queries.</span></div><div style="color: rgb(0, 0, 0); font-size: \
13.3333px; font-family: HelveticaNeue-Light,Helvetica Neue Light,Helvetica \
Neue,Helvetica,Arial,Lucida Grande,sans-serif; background-color: transparent; \
font-style: normal;"><br><span></span></div><div style="color: rgb(0, 0, 0); \
font-size: 13.3333px; font-family: HelveticaNeue-Light,Helvetica Neue Light,Helvetica \
Neue,Helvetica,Arial,Lucida Grande,sans-serif; background-color: transparent; \
font-style: normal;"><span>I also have applications that make connections and do not \
use them for hours on end. They tie up resources, and the dead-connection monitor on \
our load balancer and on the LDAP server tend to kill the connections when not in use \
that long.</span></div><div style="color: rgb(0, 0, 0); font-size: 13.3333px; \
font-family: HelveticaNeue-Light,Helvetica Neue Light,Helvetica \
Neue,Helvetica,Arial,Lucida Grande,sans-serif; background-color: transparent; \
font-style:  normal;"><br><span></span></div><div style="color: rgb(0, 0, 0); \
font-size: 13.3333px; font-family: HelveticaNeue-Light,Helvetica Neue Light,Helvetica \
Neue,Helvetica,Arial,Lucida Grande,sans-serif; background-color: transparent; \
font-style: normal;"><span>If it's going less often than between every 15-60s, then \
I'd set up and tear down for every batch of searches...<br></span></div> <div \
class="qtdSeparateBR"><br><br></div><div style="display: block;" \
class="yahoo_quoted"> <div style="font-family: HelveticaNeue-Light, Helvetica Neue \
Light, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif; font-size: \
10pt;"> <div style="font-family: HelveticaNeue, Helvetica Neue, Helvetica, Arial, \
Lucida Grande, sans-serif; font-size: 12pt;"> <div dir="ltr"> <font face="Arial" \
size="2"> On Wednesday, July 23, 2014 4:22 AM, Daniel Castro \
&lt;evil.dani@gmail.com&gt; wrote:<br> </font> </div>  <br><br> <div \
class="y_msg_container"><div id="yiv2689857999"><div  dir="ltr">Hello \
Guys,<div><br></div><div>I wrote a script that runs as a system process. If I do \
constant searches on the LDAP server how often should I bind and unbind from the \
server.</div><div><br></div><div>Should I do only one and maintain it. But what about \
if it disconnects due to inactivity during the night. Can I simply bind again on the \
same object?</div> <div><br></div><div>Or should I bind, then search, then unbind \
each time?</div><div><br></div><div>Advice?</div><div><br></div><div>Thanks,<br \
clear="all"><div><br></div>-- <br>+-=====---------------------------+<br>| \
+---------------------------------+ | This space intentionally blank for \
notetaking.<br> | |&nbsp;&nbsp; | Daniel Castro,&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; \
&nbsp; &nbsp; &nbsp; | <br>| |&nbsp;&nbsp; | Consultant/Programmer.|<br>| \
|&nbsp;&nbsp; | U Andes&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; \
&nbsp; &nbsp; &nbsp;&nbsp; |<br>+-------------------------------------+<br> \
</div></div></div><br><br></div>  </div> </div>  </div> </div></body></html>



[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic