extended provision-backend

Andrew Bartlett abartlet at samba.org
Thu Aug 6 20:47:31 MDT 2009


On Fri, 2009-08-07 at 10:16 +1000, Andrew Bartlett wrote:
> On Fri, 2009-08-07 at 01:48 +0200, Oliver Liebel wrote:
> > 
> > Andrew Bartlett schrieb:
> > > On Fri, 2009-08-07 at 01:09 +0200, Oliver Liebel wrote:
> > >   
> > >> Andrew Bartlett schrieb:
> > >>     
> > >>> On Thu, 2009-08-06 at 13:58 +0200, Oliver Liebel wrote:
> > >>>   
> > >>>       
> > >>>> Andrew Bartlett schrieb:
> > >>>>     
> > >>>>         
> > >>>>>       
> > >>>>> Thank-you so much for this work.  I've been thinking about it, and the
> > >>>>> main thing I dislike is the way you try to detect another slapd process
> > >>>>> using ps and grep.  Instead, how about trying a rootDSE search against
> > >>>>> the ldapi socket?  
> > >>>>>       
> > >>>>>           
> > >>>> what about a simple bind via python-ldap to the socket?
> > >>>> that should do it too.
> > >>>> tested ist, seems ok.
> > >>>>     
> > >>>>         
> > >>> That would work.  However I would prefer to use the ldb bindings if
> > >>> possible.  See the Ldb module. 
> > >>>
> > >>> (not that I think using python-ldap would be a big extra burden in terms
> > >>> of dependences, but because it means a future maintainer of the script
> > >>> would not have to learn another module and pattern). 
> > >>>
> > >>> Andrew Bartlett
> > >>>   
> > >>>       
> > >> hi andrew,
> > >> here is the second (and hopefully...) final edition.
> > >>     
> > >
> > > Good, but don't go around killing processes until you have confirmed
> > > that it's actually listening on the port.  (The pid file could be left
> > > around, and another process could have that pid)
> > >   
> > > I would really prefer not to do the kill at all - perhaps just print out
> > > what PID we think is still listening there.  That is: do the ldap search
> > > test first.
> > >   
> > that should be fixed quick.
> > first ldapsearch, then check if slapd-"provision"-pid == slapd.pid, then 
> > kill. ok.
> 
> I'm not sure how you intend to check the PID, but as I said, I would
> prefer not to kill in the script, just print the PID. 

I've now read the patch more carefully.  This seems like a great
approach!

> > > Also, if you could try and use the Ldb module, 
> > thats matter of time. next weeks i have very limited time.
> > what about that: ill fix the "kill"-order, and we put the improvements
> > (with python-ldap) into the next alpha, so that we can get more 
> > testing-feedback.
> > functionality should be ok, i have verified it several times with all 
> > setup-types.
> > 
> > we could handle the change from python-ldap to ldb transparently to the 
> > users
> > in the next evolution step, when both scripts are merged.
> 
> I'll handle both the Ldb change and integration if you don't have time. 
> 
> Andrew Bartlett
> 
-- 
Andrew Bartlett
http://samba.org/~abartlet/
Authentication Developer, Samba Team           http://samba.org
Samba Developer, Cisco Inc.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
URL: <http://lists.samba.org/pipermail/samba-technical/attachments/20090807/a40dc39a/attachment.pgp>


More information about the samba-technical mailing list