Hello!
I hope you can help me, migrate my old ldap-db, problem is this:
Our old server was running with ldap2.2.7? to serve as backend to the sambaserver and as of today its refusing to work or give errors (the ldap-daemon seems to start, but doesn't open the port, is not accessible, gives no errors and has to be killed, because stopping it gives no reaction)
now, i've set up a new machine, to use ldap, given it the same suffix, cn, etc. the version of ldap is a newer one, than on the old box, although i'm not sure, how far they are removed.
is it in some way possible, to just copy the files in /var/lib/ldap/ from the old server and insert them into the new box in the same folder? if so, which files would be ok to overwrite, which not? or woul i have to tweak some other files for that as well?
or is this completely inconceivable (as i dread is the case), and if yes, how am i to get the files from the old server to the new one?
any help on this would be greatly appreciated
bye silvana
Hello,
Silvana lupin5th@synphors.net writes:
Hello!
I hope you can help me, migrate my old ldap-db, problem is this:
Our old server was running with ldap2.2.7? to serve as backend to the sambaserver and as of today its refusing to work or give errors (the ldap-daemon seems to start, but doesn't open the port, is not accessible, gives no errors and has to be killed, because stopping it gives no reaction)
now, i've set up a new machine, to use ldap, given it the same suffix, cn, etc. the version of ldap is a newer one, than on the old box, although i'm not sure, how far they are removed.
is it in some way possible, to just copy the files in /var/lib/ldap/ from the old server and insert them into the new box in the same folder? if so, which files would be ok to overwrite, which not? or woul i have to tweak some other files for that as well?
or is this completely inconceivable (as i dread is the case), and if yes, how am i to get the files from the old server to the new one?
any help on this would be greatly appreciated
It is quite likely that your database got corrupted somewhow, so depending on the database definition you may try to recover the data first. If you had defined 'database bdb' in slapd.conf you may try to recover the database with the BerkeleyDB tool db_recover, if you had defined database ldbm, you lost. To add a database to a new OpenLDAp instance the proper way is to dump the old data to a file, using the tool slapcat(8) and slapadd(8) to the new instance. As you presumably have built OpenLDAP with a newer version of BerkeleyDB, just copying files is not appropriate.
-Dieter
On Sat, November 8, 2008 05:30, Dieter Kluenter wrote:
Hello,
It is quite likely that your database got corrupted somewhow, so depending on the database definition you may try to recover the data first. If you had defined 'database bdb' in slapd.conf you may try to recover the database with the BerkeleyDB tool db_recover, if you had defined database ldbm, you lost.
ok, I`m really glad, because it is indeed bdb. i`ll try that first now, although i`ll first have to wrangle suse 10.0 to get said tool. I didn`t set up the server, i just have to deal with it now, and my suse-fu is not the strongest ;-)
To add a database to a new OpenLDAp instance the proper way is to dump the old data to a file, using the tool slapcat(8) and slapadd(8) to the new instance. As you presumably have built OpenLDAP with a newer version of BerkeleyDB, just copying files is not appropriate.
ok, i`l try that, too. thank you very much for the hints, i hope it helps.
although i`m wondering, if the db got corrupted, shouldn`t ldap complain about it in the logs? as it is, after "rcldap start" the daemon is visible in ps -A, but is not responding. and in the logs it just says it is initialised, no complains or errors etc?
anyways, thank you very much!
Silvana
-Dieter
-- Dieter Klünter | Systemberatung sip: +49.180.1555.7770535 http://www.dpunkt.de/buecher/2104.html GPG Key ID:8EF7B6C6
Am Samstag 08 November 2008 11:47:49 schrieb Silvana:
On Sat, November 8, 2008 05:30, Dieter Kluenter wrote:
Hello,
It is quite likely that your database got corrupted somewhow, so depending on the database definition you may try to recover the data first. If you had defined 'database bdb' in slapd.conf you may try to recover the database with the BerkeleyDB tool db_recover, if you had defined database ldbm, you lost.
ok, I`m really glad, because it is indeed bdb. i`ll try that first now, although i`ll first have to wrangle suse 10.0 to get said tool. I didn`t set up the server, i just have to deal with it now, and my suse-fu is not the strongest ;-)
You can find the db_recover tool in the "db-utils" RPM on the installation media.
To add a database to a new OpenLDAp instance the proper way is to dump the old data to a file, using the tool slapcat(8) and slapadd(8) to the new instance. As you presumably have built OpenLDAP with a newer version of BerkeleyDB, just copying files is not appropriate.
ok, i`l try that, too. thank you very much for the hints, i hope it helps.
although i`m wondering, if the db got corrupted, shouldn`t ldap complain about it in the logs? as it is, after "rcldap start" the daemon is visible in ps -A, but is not responding. and in the logs it just says it is initialised, no complains or errors etc?
You are running a very old OpenLDAP release it seems. Newer Versions of OpenLDAP (IIRC since some 2.3 release) can detect automatically recover in many situation were a manual db_recover was needed in the past.
openldap-technical@openldap.org