Hi All,
I'm in need of figuring out how I can effectively backup my ldap server then restore it in case of crisis. 

I have a master and consumer ldap server running in replication mode with latest ldap 2.4 version on ubuntu 10.  I have an idea on backup and restore procedures but I need verification.

Backup procedures:

1. /etc/init.d/slapd stop

2.  tar the following directories
/etc/ldap
/var/lib/ldap

# tar -pczf compressed.tar.gz /etc/ldap/ /var/lib/ldap/

3.  convert the configs and dit to ldif
sudo slapcat -n 0 > backup/config.ldif
sudo slapcat -n 1 > backup/users.ldif

4./etc/init.d/slapd start

Restore procedures:

1.  Reinstall a fresh vanilla ubuntu ldap server

2.  untar the compessed.tar.gz to original location

3.  /etc/init.d/slapd stop sudo slapadd -n 0 -l backup/config.ldif sudo slapadd -n 0 -l backup/users.ldif sudo cp backup/ldap.secret /etc/ldap.secret /etc/init.d/slapd start

Just a brainstorm and I'm sure it needs revising.

TIA,
Anton