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

RE: OK, so I'm being a pest, but where does one find ldif2ldbm?

Title: Message
You may not need to find this ldif2ldbm if you're starting from scratch. When you built openldap (2.0.18 i'm assuming) you should have also installed some sort of db libraries. Typically these libraries come in the form of Berkeley Soft (Sleepycat's) DB software. Before you fire up ldap, you'll have to create a database. Using ldbm as your database, you can create the necessary information by editing your slapd.conf. Here's a sample:
database        ldbm
cachesize       100000
dbcachesize     1000000
directory       /export/myldap/ldapdb
suffix          "o=MyCompany"
rootdn          "cn=root,ou=MyAdmin,ou=Marketing,o=MyCompany"
rootpw          secret
# ldbm indexed attribute definitions
# create indexes
index objectClass pres,eq
Then add the suffix and the rootdn by following http://www.openldap.org/doc/admin/dbtools.html Section 7.1 Creating a database, pay particular attention to the example right before section 7.2
        # entries.ldif
        # Organization for Example Corporation
        dn: dc=example,dc=com
        objectClass: dcObject
        objectClass: organization
        dc: example
        o: Example Corporation
        description: The Example Corporation
        # Organizational Role for Directory Manager
        dn: cn=Manager,dc=example,dc=com
        objectClass: organizationalRole
        cn: Manager
        description: Directory Manager
edit this template to suit your organization's needs and then issue the command
ldapadd -f entries.ldif -x -D "cn=root,ou=MyAdmin,ou=Marketing,o=MyCompany" -w secret
If you're running slapd as a different user as root, you'll have to chmod permissions of the resulting dbb in /export/myldap/ldapdb to that user. ask you sys admin for help if you need to locate where the dbb files are , mine looks like:
ls *.dbb
cn.dbb           id2entry.dbb     objectClass.dbb  uid.dbb
dn2id.dbb        nextid.dbb       sn.dbb
after creating this.
-----Original Message-----
From: owner-openldap-software@OpenLDAP.org [mailto:owner-openldap-software@OpenLDAP.org]On Behalf Of Rob Vieira
Sent: Monday, December 31, 2001 3:30 PM
To: openldap-software@OpenLDAP.org
Subject: OK, so I'm being a pest, but where does one find ldif2ldbm?

In an earlier thread, I indicated that I was highly suspicious of the fact that I didn't seem to have any kind of starter databases. I can't find them in any of the distributions, nor can I find any reference to creating them in the "quick start" guide.
After running the trace information, I find that it indicates that it can't find a file called dn2id.dbb. Several posts in the search engine seem to indicate that I need to run a utility called ldif2ldbm in order to create the dbb files. This would, however, only get me so far since I don't have any starter kind of ldif files - it would seem that I might be able to run it against the core.schema file? (just a guess?).
My apologies for so many of the rookie questions - I'm really trying to read and digest things and find my own answers before asking, but I'm not getting very far.