[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: openldap on Linux/alpha (ITS#295)



Andrew Kemp wrote:
> On 19/09/99 at 05:33:24 +0000, Kurt@OpenLDAP.org spoke thus :
> > >db_appinit(3) ERRORS
> > >EINVAL:      The DB_THREAD flag was specified and spinlocks are not implemented for this architecture.
> > >
> > >No spinlocks under Linux/alpha?
> >
> > Looks like BerkeleyDB does not support GCC spinlocks under
> > Linux/alpha (or other non-x86 architectures).
> 
> This is not specific to Linux - if you are using Digital Unix 4.x
> on an Alpha (as we are) then you also have the problem with spinlocks.

BerkeleyDB appears to only support DB_THREAD under a fairly limited
set of platforms (as the code is written in assembler).
Looks like we should implement a configure test to see if
DB_THREAD is currently supported and if not fall back to
LDBM level locking (as we do for GDBM and BDB1).

> This appears to be what is also causing me problems with installing any
> version of OpenLDAP since DB2 became mandatory.

BerkeleyDB is not mandatory.  Either BerkeleyDB or GDBM are required for
LDBM databases.  In either case, only recent versions are supported.
BerkeleyDB 2.7.5 (or better) or GDBM 1.8.

> > GDBM and BerkeleyDB (without DB_THREAD support) should yield about the same
> > performance for small directories.
> 
> And for large directories ? We have at least 50K+ individuals in
> our directory at present.

Well, I believe BerkeleyDB can be significantly faster on cache and disk
operations.  However, if slapd is setup with large LDBM caching, you may
never notice the difference.

I would consider it wise for developers to invest a little time implementing
Berkeley DB_THREAD support for their platform so that you can take full
advantage of the BDB2-specific backend when it becomes available.