In the slapd.conf file of a provider server I have the following suffix parameter:
suffix "dc=example,dc=org"
And with slapcat I see the followind:
dn: dc=example,dc=org objectClass: top objectClass: dcObject objectClass: organization o: example.org dc: example structuralObjectClass: organization entryUUID: ead90d7a-c02b-102c-8c00-cb58049f9ef6 creatorsName: modifiersName: createTimestamp: 20080527112930Z modifyTimestamp: 20080527112930Z entryCSN: 20080527112930.000000Z#000000#000#000000
I wanted to set a consumer but I set the suffix parameter wrong:
suffix "dc=corp,dc=example,dc=org"
So this was created:
dn: objectClass: top objectClass: dcObject objectClass: organization o: corp.example.org dc: corp structuralObjectClass: organization entryUUID: 29af5532-1abb-102e-9f19-896497a83f9b creatorsName: createTimestamp: 20090811120636Z entryCSN: 20090811120636.425151Z#000000#000#000000 modifiersName: modifyTimestamp: 20090811120636Z
Is there any way to change this? I also don't know why the dn in the second case is empty (I thought it should be dc=corp,dc=example,dc=org). If this can't be easily fixed, is there any way of starting from scratch?
Regards.
Hello - apologies if this is a dumb question, I am an LDAP newbie. I have an LDAP server on another machine and I need to duplicate it, but I am having trouble importing the ldif file.
I do a dump of the LDAP data with this command:
nice slapcat > /home/upadmin/uportal_ldap_backups/`date +%m%d%Y_%H%M`_ldap_backup.ldif
I move the resulting ldif file to my other server and test the import:
slapadd -v -u -c -f /usr/local/etc/openldap/slapd.conf -l /root/08052009_0647_ldap_backup.ldif
The output seems good - I get:
added: "dc=sbceoportal,dc=org" added: "ou=Users,dc=sbceoportal,dc=org" added: "ou=Groups,dc=sbceoportal,dc=org" added: "ou=System,dc=sbceoportal,dc=org" added: "cn=LDAP Admins,ou=Groups,dc=sbceoportal,dc=org" .#################### 100.00% eta none elapsed none fast!
Then I run the command to do the real import:
slapadd -v -f /usr/local/etc/openldap/slapd.conf -l /root/08052009_0647_ldap_backup.ldif
And the import hangs on the first record. This is the output I get:
bdb_monitor_db_open: monitoring disabled; configure monitor database to enable added: "dc=sbceoportal,dc=org" (00000001)
And it just seems to sit there and never finish. Anyone have any idea what is going on or anything I can do to troubleshoot this?
Thanks so much! Kristen
PS This is a snippet from the top of the ldif file I am using to import:
dn: dc=sbceoportal,dc=org description: Sbceoportal.org - the greatest Portal ever! dc: sbceoportal o: Sbceoportal.org objectClass: top objectClass: dcObject objectClass: organization structuralObjectClass: organization entryUUID: e15a62b4-0264-102d-91f5-e7cc24931947 creatorsName: cn=Manager,dc=sbceoportal,dc=org createTimestamp: 20080819180332Z entryCSN: 20080819180332Z#000000#00#000000 modifiersName: cn=Manager,dc=sbceoportal,dc=org modifyTimestamp: 20080819180332Z
dn: ou=Users,dc=sbceoportal,dc=org ou: Users description: Example.Com Users objectClass: organizationalUnit structuralObjectClass: organizationalUnit entryUUID: e16778d2-0264-102d-91f6-e7cc24931947 creatorsName: cn=Manager,dc=sbceoportal,dc=org createTimestamp: 20080819180332Z entryCSN: 20080819180332Z#000001#00#000000 modifiersName: cn=Manager,dc=sbceoportal,dc=org modifyTimestamp: 20080819180332Z
dn: ou=Groups,dc=sbceoportal,dc=org ou: Groups description: Example.Com Groups objectClass: organizationalUnit structuralObjectClass: organizationalUnit entryUUID: e16a9990-0264-102d-91f7-e7cc24931947 creatorsName: cn=Manager,dc=sbceoportal,dc=org createTimestamp: 20080819180332Z entryCSN: 20080819180332Z#000002#00#000000 modifiersName: cn=Manager,dc=sbceoportal,dc=org modifyTimestamp: 20080819180332Z
-- Kristen Walker
Digital Media Resources Developer Instructional Media Services Santa Barbara County Education Office 4400 Cathedral Oaks Road P.O. Box 6307 Santa Barbara, CA 93160-6307 (805)964-4711 ext. 5244/FAX (805)683-3597 kwalker@sbceo.org http://www.sbceoportal.org
--On Wednesday, August 12, 2009 9:27 AM -0700 Kristen Walker kwalker@sbceo.org wrote:
Hello - apologies if this is a dumb question, I am an LDAP newbie. I have an LDAP server on another machine and I need to duplicate it, but I am having trouble importing the ldif file.
I do a dump of the LDAP data with this command:
nice slapcat > /home/upadmin/uportal_ldap_backups/`date +%m%d%Y_%H%M`_ldap_backup.ldif
I move the resulting ldif file to my other server and test the import:
slapadd -v -u -c -f /usr/local/etc/openldap/slapd.conf -l /root/08052009_0647_ldap_backup.ldif
The output seems good - I get:
added: "dc=sbceoportal,dc=org" added: "ou=Users,dc=sbceoportal,dc=org" added: "ou=Groups,dc=sbceoportal,dc=org" added: "ou=System,dc=sbceoportal,dc=org" added: "cn=LDAP Admins,ou=Groups,dc=sbceoportal,dc=org" .#################### 100.00% eta none elapsed none fast!
Then I run the command to do the real import:
slapadd -v -f /usr/local/etc/openldap/slapd.conf -l /root/08052009_0647_ldap_backup.ldif
And the import hangs on the first record. This is the output I get:
bdb_monitor_db_open: monitoring disabled; configure monitor database to enable added: "dc=sbceoportal,dc=org" (00000001)
And it just seems to sit there and never finish. Anyone have any idea what is going on or anything I can do to troubleshoot this?
A couple of things:
Do you have a DB_CONFIG file?
Does the progress bar show up?
Does the server you are adding to already have a database?
Have you thought about using the "-q" flag to slapadd?
--Quanah
--
Quanah Gibson-Mount Principal Software Engineer Zimbra, Inc -------------------- Zimbra :: the leader in open source messaging and collaboration
On 8/12/09 9:50 AM, "Quanah Gibson-Mount" quanah@zimbra.com wrote:
--On Wednesday, August 12, 2009 9:27 AM -0700 Kristen Walker kwalker@sbceo.org wrote:
Hello - apologies if this is a dumb question, I am an LDAP newbie. I have an LDAP server on another machine and I need to duplicate it, but I am having trouble importing the ldif file.
I do a dump of the LDAP data with this command:
nice slapcat > /home/upadmin/uportal_ldap_backups/`date +%m%d%Y_%H%M`_ldap_backup.ldif
I move the resulting ldif file to my other server and test the import:
slapadd -v -u -c -f /usr/local/etc/openldap/slapd.conf -l /root/08052009_0647_ldap_backup.ldif
The output seems good - I get:
added: "dc=sbceoportal,dc=org" added: "ou=Users,dc=sbceoportal,dc=org" added: "ou=Groups,dc=sbceoportal,dc=org" added: "ou=System,dc=sbceoportal,dc=org" added: "cn=LDAP Admins,ou=Groups,dc=sbceoportal,dc=org" .#################### 100.00% eta none elapsed none fast!
Then I run the command to do the real import:
slapadd -v -f /usr/local/etc/openldap/slapd.conf -l /root/08052009_0647_ldap_backup.ldif
And the import hangs on the first record. This is the output I get:
bdb_monitor_db_open: monitoring disabled; configure monitor database to enable added: "dc=sbceoportal,dc=org" (00000001)
And it just seems to sit there and never finish. Anyone have any idea what is going on or anything I can do to troubleshoot this?
A couple of things:
Do you have a DB_CONFIG file?
Does the progress bar show up?
Does the server you are adding to already have a database?
Have you thought about using the "-q" flag to slapadd?
--Quanah
--
Quanah Gibson-Mount Principal Software Engineer Zimbra, Inc
Zimbra :: the leader in open source messaging and collaboration
I have a DB_CONFIG, here are the contents:
************************************************************************** # $OpenLDAP: pkg/ldap/servers/slapd/DB_CONFIG,v 1.3.2.4 2007/12/18 11:53:27 ghenry Exp $ # Example DB_CONFIG file for use with slapd(8) BDB/HDB databases. # # See the Oracle Berkeley DB documentation # http://www.oracle.com/technology/documentation/berkeley-db/db/ref/env/db_co nfig.html # for detail description of DB_CONFIG syntax and semantics. # # Hints can also be found in the OpenLDAP Software FAQ # http://www.openldap.org/faq/index.cgi?file=2 # in particular: # http://www.openldap.org/faq/index.cgi?file=1075
# Note: most DB_CONFIG settings will take effect only upon rebuilding # the DB environment.
# one 0.25 GB cache set_cachesize 0 268435456 1
# Data Directory #set_data_dir db
# Transaction Log settings set_lg_regionmax 262144 set_lg_bsize 2097152 #set_lg_dir logs
# Note: special DB_CONFIG flags are no longer needed for "quick" # slapadd(8) or slapindex(8) access (see their -q option). **************************************************************************
I don't see a progress bar when I try the import, it just seems to hang. The server I am adding to does not have a database. I do a rm __db.* *.bdb log.* in the openldap-data directory after the failed imports so that I wipe out the database each time and start over.
I haven't tried the -q flag and got this:
slapadd -q -v -f /usr/local/etc/openldap/slapd.conf -l /root/08052009_0647_ldap_backup.ldif bdb_db_open: database "dc=sbceoportal,dc=org": unclean shutdown detected; attempting recovery. bdb(dc=sbceoportal,dc=org): recovery requires transaction support bdb_db_open: database "dc=sbceoportal,dc=org" cannot be recovered, err 22. Restore from backup! backend_startup_one: bi_db_open failed! (22) slap_startup failed
Thanks! Kristen
-- Kristen Walker
Digital Media Resources Developer Instructional Media Services Santa Barbara County Education Office 4400 Cathedral Oaks Road P.O. Box 6307 Santa Barbara, CA 93160-6307 (805)964-4711 ext. 5244/FAX (805)683-3597 kwalker@sbceo.org http://www.sbceoportal.org
--On Wednesday, August 12, 2009 9:59 AM -0700 Kristen Walker kwalker@sbceo.org wrote:
I don't see a progress bar when I try the import, it just seems to hang. The server I am adding to does not have a database. I do a rm __db.* *.bdb log.* in the openldap-data directory after the failed imports so that I wipe out the database each time and start over.
I haven't tried the -q flag and got this:
slapadd -q -v -f /usr/local/etc/openldap/slapd.conf -l /root/08052009_0647_ldap_backup.ldif bdb_db_open: database "dc=sbceoportal,dc=org": unclean shutdown detected; attempting recovery. bdb(dc=sbceoportal,dc=org): recovery requires transaction support bdb_db_open: database "dc=sbceoportal,dc=org" cannot be recovered, err 22. Restore from backup! backend_startup_one: bi_db_open failed! (22) slap_startup failed
Do you have slapd running on the server you are restoring to? slapd must be shutdown for slapadd to operate, it is an offline command.
--Quanah
--
Quanah Gibson-Mount Principal Software Engineer Zimbra, Inc -------------------- Zimbra :: the leader in open source messaging and collaboration
On 8/12/09 10:16 AM, "Quanah Gibson-Mount" quanah@zimbra.com wrote:
--On Wednesday, August 12, 2009 9:59 AM -0700 Kristen Walker kwalker@sbceo.org wrote:
I don't see a progress bar when I try the import, it just seems to hang. The server I am adding to does not have a database. I do a rm __db.* *.bdb log.* in the openldap-data directory after the failed imports so that I wipe out the database each time and start over.
I haven't tried the -q flag and got this:
slapadd -q -v -f /usr/local/etc/openldap/slapd.conf -l /root/08052009_0647_ldap_backup.ldif bdb_db_open: database "dc=sbceoportal,dc=org": unclean shutdown detected; attempting recovery. bdb(dc=sbceoportal,dc=org): recovery requires transaction support bdb_db_open: database "dc=sbceoportal,dc=org" cannot be recovered, err 22. Restore from backup! backend_startup_one: bi_db_open failed! (22) slap_startup failed
Do you have slapd running on the server you are restoring to? slapd must be shutdown for slapadd to operate, it is an offline command.
--Quanah
Slapd is not running on the server:
root@domU-12-31-38-00-42-32:~# ps aux | grep slapd
root 29033 0.0 0.0 3420 768 pts/1 R+ 17:19 0:00 grep slapd
root@domU-12-31-38-00-42-32:~# slapadd -q -v -f /usr/local/etc/openldap/slapd.conf -l /root/08052009_0647_ldap_backup.ldif
bdb_db_open: database "dc=sbceoportal,dc=org": unclean shutdown detected; attempting recovery. bdb_db_open: database "dc=sbceoportal,dc=org": cannot recover, database must be reinitialized. backend_startup_one: bi_db_open failed! (-1) slap_startup failed root@domU-12-31-38-00-42-32:~#
Thanks, Kristen
-- Kristen Walker
Digital Media Resources Developer Instructional Media Services Santa Barbara County Education Office 4400 Cathedral Oaks Road P.O. Box 6307 Santa Barbara, CA 93160-6307 (805)964-4711 ext. 5244/FAX (805)683-3597 kwalker@sbceo.org http://www.sbceoportal.org
What version of BDB are you using? If 4.7.25, does it contain the Oracle patches?
On Wed, Aug 12, 2009 at 11:18 AM, Kristen Walker kwalker@sbceo.org wrote:
On 8/12/09 10:16 AM, "Quanah Gibson-Mount" quanah@zimbra.com wrote:
--On Wednesday, August 12, 2009 9:59 AM -0700 Kristen Walker kwalker@sbceo.org wrote:
I don't see a progress bar when I try the import, it just seems to hang. The server I am adding to does not have a database. I do a rm __db.* *.bdb log.* in the openldap-data directory after the failed imports so that I wipe out the database each time and start over.
I haven't tried the -q flag and got this:
slapadd -q -v -f /usr/local/etc/openldap/slapd.conf -l /root/08052009_0647_ldap_backup.ldif bdb_db_open: database "dc=sbceoportal,dc=org": unclean shutdown
detected;
attempting recovery. bdb(dc=sbceoportal,dc=org): recovery requires transaction support bdb_db_open: database "dc=sbceoportal,dc=org" cannot be recovered, err
Restore from backup! backend_startup_one: bi_db_open failed! (22) slap_startup failed
Do you have slapd running on the server you are restoring to? slapd must be shutdown for slapadd to operate, it is an offline command.
--Quanah
Slapd is not running on the server:
root@domU-12-31-38-00-42-32:~# ps aux | grep slapd
root 29033 0.0 0.0 3420 768 pts/1 R+ 17:19 0:00 grep slapd
root@domU-12-31-38-00-42-32:~# slapadd -q -v -f /usr/local/etc/openldap/slapd.conf -l /root/08052009_0647_ldap_backup.ldif
bdb_db_open: database "dc=sbceoportal,dc=org": unclean shutdown detected; attempting recovery. bdb_db_open: database "dc=sbceoportal,dc=org": cannot recover, database must be reinitialized. backend_startup_one: bi_db_open failed! (-1) slap_startup failed root@domU-12-31-38-00-42-32:~#
Thanks, Kristen
-- Kristen Walker
Digital Media Resources Developer Instructional Media Services Santa Barbara County Education Office 4400 Cathedral Oaks Road P.O. Box 6307 Santa Barbara, CA 93160-6307 (805)964-4711 ext. 5244/FAX (805)683-3597 kwalker@sbceo.org http://www.sbceoportal.org
On 8/12/09 10:28 AM, "Matt Kassawara" battery@writeme.com wrote:
What version of BDB are you using? If 4.7.25, does it contain the Oracle patches?
It looks like it is 4.7.25. I haven¹t applied any patches. Where can I get them? How can I find out if it has the patches or not?
Thanks, Kristen
-- Kristen Walker
Digital Media Resources Developer Instructional Media Services Santa Barbara County Education Office 4400 Cathedral Oaks Road P.O. Box 6307 Santa Barbara, CA 93160-6307 (805)964-4711 ext. 5244/FAX (805)683-3597 kwalker@sbceo.org http://www.sbceoportal.org
--On Wednesday, August 12, 2009 10:37 AM -0700 Kristen Walker kwalker@sbceo.org wrote:
On 8/12/09 10:28 AM, "Matt Kassawara" battery@writeme.com wrote:
What version of BDB are you using? If 4.7.25, does it contain the Oracle patches?
It looks like it is 4.7.25. I haven't applied any patches. Where can I get them? How can I find out if it has the patches or not?
Go to the BDB section, and download the patches, apply them, and rebuild.
--Quanah
--
Quanah Gibson-Mount Principal Software Engineer Zimbra, Inc -------------------- Zimbra :: the leader in open source messaging and collaboration
Go to the BDB section, and download the patches, apply them, and rebuild.
--Quanah
This might seem like a silly question, but is there an easy way to apply these patches or do I have to go into the actual source files and make the edits? Is there a latest and greatest version of BerkelyDB that I can grab that already includes these patches?
Thanks!
-Kristen
-- Kristen Walker
Digital Media Resources Developer Instructional Media Services Santa Barbara County Education Office 4400 Cathedral Oaks Road P.O. Box 6307 Santa Barbara, CA 93160-6307 (805)964-4711 ext. 5244/FAX (805)683-3597 kwalker@sbceo.org http://www.sbceoportal.org
Where did you get your current BDB packages?
On Wed, Aug 12, 2009 at 2:13 PM, Kristen Walker kwalker@sbceo.org wrote:
Go to the BDB section, and download the patches, apply them, and rebuild.
--Quanah
This might seem like a silly question, but is there an easy way to apply these patches or do I have to go into the actual source files and make the edits? Is there a latest and greatest version of BerkelyDB that I can grab that already includes these patches?
Thanks!
-Kristen
-- Kristen Walker
Digital Media Resources Developer Instructional Media Services Santa Barbara County Education Office 4400 Cathedral Oaks Road P.O. Box 6307 Santa Barbara, CA 93160-6307 (805)964-4711 ext. 5244/FAX (805)683-3597 kwalker@sbceo.org http://www.sbceoportal.org
On 8/12/09 1:27 PM, "Matt Kassawara" battery@writeme.com wrote:
Where did you get your current BDB packages?
I got them here: http://www.oracle.com/technology/software/products/berkeley-db/db/index.html
-Kristen
-- Kristen Walker
Digital Media Resources Developer Instructional Media Services Santa Barbara County Education Office 4400 Cathedral Oaks Road P.O. Box 6307 Santa Barbara, CA 93160-6307 (805)964-4711 ext. 5244/FAX (805)683-3597 kwalker@sbceo.org http://www.sbceoportal.org
So you or someone else built them instead of getting prebuilt packages from a Linux distro... then you'll need to follow Quanah's advice on rebuilding BDB from source with the patches.
On Wed, Aug 12, 2009 at 2:40 PM, Kristen Walker kwalker@sbceo.org wrote:
On 8/12/09 1:27 PM, "Matt Kassawara" battery@writeme.com wrote:
Where did you get your current BDB packages?
I got them here:
http://www.oracle.com/technology/software/products/berkeley-db/db/index.html
-Kristen
-- Kristen Walker
Digital Media Resources Developer Instructional Media Services Santa Barbara County Education Office 4400 Cathedral Oaks Road P.O. Box 6307 Santa Barbara, CA 93160-6307 (805)964-4711 ext. 5244/FAX (805)683-3597 kwalker@sbceo.org http://www.sbceoportal.org
--On Wednesday, August 12, 2009 1:13 PM -0700 Kristen Walker kwalker@sbceo.org wrote:
Go to the BDB section, and download the patches, apply them, and rebuild.
--Quanah
This might seem like a silly question, but is there an easy way to apply these patches or do I have to go into the actual source files and make the edits? Is there a latest and greatest version of BerkelyDB that I can grab that already includes these patches?
You have to apply them to the source and rebuild it.
--Quanah
--
Quanah Gibson-Mount Principal Software Engineer Zimbra, Inc -------------------- Zimbra :: the leader in open source messaging and collaboration
openldap-technical@openldap.org