Re: How to configure overlay unique in cn=config

2010-10-15 Thread Buchan Milne
On Thursday, 14 October 2010 21:23:05 Benjamin Griese wrote:
 Hey buddy,
 
 if you use Apache Directory Studio amongst other things for configuring
 overlays, it automatically gets you the right dependencies if you choose
 for example OC olcUnique, you need also need to have OC olcOverlay and
 so on, ADS automatically sets it for you in a wizard like process. Doing
 that without that tool was really a PITA, especially if are not that
 familiar with the whole package of different types of classes and schema
 dependencies.
 
 Give it a try, ADS made my life as LDAP-Admin a whole lot of easier.

Unfortunately, I don't think there is any way to know (over LDAP) whether the 
unique module is built-in, compiled as a module, or not compiled at all, so I 
don't believe ADS can help in this situation ...

[...]

  After playing a lot, I've found that it works only when both module and
  overlay is configured in files in /etc/ldap/slap.d/...
  
  (I'm using slapd 2.4.23, from Debian/Sid)
  
  For now it is enough for me, because I don't want to dynamically set
  uniqueness, but anyway documentation is not clear how it should be.

Regards,
Buchan


Re: How to configure overlay unique in cn=config

2010-10-15 Thread Howard Chu

Buchan Milne wrote:

On Thursday, 14 October 2010 21:23:05 Benjamin Griese wrote:

Hey buddy,

if you use Apache Directory Studio amongst other things for configuring
overlays, it automatically gets you the right dependencies if you choose
for example OC olcUnique, you need also need to have OC olcOverlay and
so on, ADS automatically sets it for you in a wizard like process. Doing
that without that tool was really a PITA, especially if are not that
familiar with the whole package of different types of classes and schema
dependencies.

Give it a try, ADS made my life as LDAP-Admin a whole lot of easier.


Unfortunately, I don't think there is any way to know (over LDAP) whether the
unique module is built-in, compiled as a module, or not compiled at all, so I
don't believe ADS can help in this situation ...


The Samba folks were complaining about this ambiguity a while back. Which is 
why we recommended that they just always issue the moduleload statements. They 
will be ignored/no-op'd if the module was already built in.


Likewise, the default modulepath is always compiled in, so there's no need to 
set it unless you're loading a custom module of your own from some other location.


--
  -- Howard Chu
  CTO, Symas Corp.   http://www.symas.com
  Director, Highland Sun http://highlandsun.com/hyc/
  Chief Architect, OpenLDAP  http://www.openldap.org/project/


How to configure overlay unique in cn=config

2010-10-14 Thread Jarek
Hello!

I'm trying to configure unique attribue:

unique.ldiff:

dn: olcOverlay=unique,olcDatabase={1}hdb,cn=config
objectClass: olcOverlayConfig
objectClass: olcUniqueConfig
olcOverlay: unique
olcUniqueAttribute: mail


ldapadd -v -Y EXTERNAL -H ldapi:///  -f unique.ldiff
ldap_initialize( ldapi:///??base )
SASL/EXTERNAL authentication started
SASL username: gidNumber=0+uidNumber=0,cn=peercred,cn=external,cn=auth
SASL SSF: 0
add objectClass:
olcOverlayConfig
olcUniqueConfig
add olcOverlay:
unique
add olcUniqueAttribute:
mail
adding new entry olcOverlay=unique,olcDatabase={1}hdb,cn=config
ldap_add: Invalid syntax (21)
additional info: objectClass: value #1 invalid per syntax

What I'm doing wrong ?
-- 
Jarek ja...@poczta.srv.pl



Re: How to configure overlay unique in cn=config

2010-10-14 Thread Benjamin Griese
Hey buddy,

if you use Apache Directory Studio amongst other things for configuring
overlays, it automatically gets you the right dependencies if you choose for
example OC olcUnique, you need also need to have OC olcOverlay and so
on, ADS automatically sets it for you in a wizard like process. Doing that
without that tool was really a PITA, especially if are not that familiar
with the whole package of different types of classes and schema
dependencies.

Give it a try, ADS made my life as LDAP-Admin a whole lot of easier.

Bye.

http://directory.apache.org/studio/index.html

PS: sounds like I am a PR agent for apache. :/

2010/10/14 Jarek ja...@poczta.srv.pl

 Hello!

 Dnia 2010-10-14, czw o godzinie 16:31 -0300, Diego Lima pisze:
 [cut]
  I'd guess you haven't loaded the unique module before adding the
  overlay. Try adding this LDIF:

 Thanks for the answer.
 After playing a lot, I've found that it works only when both module and
 overlay is configured in files in /etc/ldap/slap.d/...

 (I'm using slapd 2.4.23, from Debian/Sid)

 For now it is enough for me, because I don't want to dynamically set
 uniqueness, but anyway documentation is not clear how it should be.

 best regards
 --
 Jarek ja...@poczta.srv.pl




-- 
To be or not to be -- Shakespeare | To do is to be -- Nietzsche | To be is
to do -- Sartre | Do be do be do -- Sinatra