From: <ma...@mj...> - 2002-06-04 02:24:37
|
This would be a lot simpler if you just stuck a static IP up front via a hardware based balancer :). Anyway, there's an old message at: http://www.rosat.mpe-garching.mpg.de/mailing-lists/perl-ldap/2001- 07/msg00103.html that's probably closer to what you're looking for. But you might also be able to do something with a callback to die more gracefully and then restart the search. or buid a local cache and if the URL is not in cache or has timed out of your cache, then do the search. That way you don't have to keep an LDAP connection open all of the time. And yet another way would be to do a persistent search control (if Novell supports it) Mark On 3 Jun 02, at 20:29, Mike Richichi wrote: > I'm using perl-ldap for an Apache rewrite handler to provide mappings > to Novell NetWare home directories that are mounted as shares on our > Linux box. This means I'm binding once when Apache is started and the > script runs continually, with Apache passing things to the script to > rewrite. > > We're transitioning to Novell Cluster Services, and it's easy to point > 'ldap' to the cluster IP address, which will always be available on a > cluster node. However, if the IP address moves, my script will no > longer work, as the LDAP connection no longer isn't known on the new > server (the TCP connection tables do not move over when the cluster > fails over). > > Thus I need to have a mechanism for timing out a bad connection and > rebinding in the event of a server failure. > > This would also be useful in general for sites doing round-robin DNS > of their ldap hostname, and resiliency in general. > > I feel that binding asynchronously and polling for results is the way > to go, but I've not seen an example of how to poll asynchronously in > perl-ldap. Has anyone done it? Alternately, can anyone suggest a > better way to detect a stale connection and attempt to rebind? > > Thanks for your help. > > --Mike > > > _______________________________________________________________ > > Don't miss the 2002 Sprint PCS Application Developer's Conference > August 25-28 in Las Vegas -- http://devcon.sprintpcs.com/adp/index.cfm > > > Mark Wilcox ma...@mj... Got LDAP? |