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

Re: backup and restore



hi alls!

ok im agree with you but only if you have to do minor changes.

the last week i had to do changes almost for everyone entry of database. i
tried several ways, but the faster (for me but i dont speak the TRUE only
that i think) is the next:
1) first dumped the database to ldif file
2) runned PERL to modify the ldif
3) edited the slapd.conf  and comment all the indexes but the objectClass
indexes.
4) used the slapdadd to make a new database
5) edited slapd.conf again and uncommented the indexes
6) used the slapindex to make the re-indexation

if your changes are minor, you should the slapadd with the indexes
uncommented but if not i think that my way is faster.

kind regards

agustin.

----- Original Message -----
From: "Frank Swasey" <Frank.Swasey@uvm.edu>
To: "Agustin" <torrest@andaluciajunta.es>
Cc: "Ron McKown" <rmckown@envenergy.com>; <openldap-software@OpenLDAP.org>
Sent: Friday, November 01, 2002 1:29 PM
Subject: Re: backup and restore


> Today at 10:27am, Agustin wrote:
>
> > hi ron!
> >
> > i have ldbm too. i have one server ant two replicas and sometimes i have
to
> > copy the  master's database to the replicas because i had problems with
> > replication.
> >
> > if you make ldif backup and later make slapadd you must do slapdindex
too to
> > re-make the indexes of the database.
> > i prefer copy the openldap/var branch completly (i have the sames
indexes at
> > the master and the slaves).
>
> Uhm... NO!
>   I'm running a Master-Slave combination on 2.0.23 and I do a "nightly
> database replacement" by stopping the server, using slapcat to dump the
> database, use a set of perl scripts to update the ldif (new information
> insertion), and then use slapadd to reload the database on the two
> machines.  I never ever have to run slapindex.  slapadd does the
> indexing for me.  I have had problems when I forgot that I was running
> these commands as root and slapd runs as ldap.... However, now that I
> also do a "chown -R ldap:ldap" against the ldbm database directory, all
> is happy and harmonious.
>
> >
> > kind regards
> >
> > agustin.
> > ----- Original Message -----
> > From: "Ron McKown" <rmckown@envenergy.com>
> > To: <openldap-software@OpenLDAP.org>
> > Sent: Thursday, October 31, 2002 8:37 PM
> > Subject: backup and restore
> >
> >
> > > Hi everyone,
> > > i'm new to LDAP and i've read the LDAP howto as well as a few
> > > administration guides.  i've implemented authentication via LDAP and
it
> > > works very well.
> > > i've run into a problem and i'm not sure i have all the facts.  i am
> > > trying to move my LDAP database from one machine to another.
> > > here's my command list:
> > > service ldap stop
> > > slapcat -f /etc/openldap/slapd.conf -l backup.ldif
> > > service ldap start
> > >
> > > i move the backup.ldif and slapd.conf file to the other computer,
then:
> > > slapadd -f /etc/opendldap/slapd.conf -l backup.ldif
> > > (i get no errors here, i'm assuming all went well).
> > > service ldap start
> > > (again, no errors)
> > >
> > > however, now it seems that there is no data in the new database.
> > > did i use the wrong commands for this operation?  is there a better
way?
> > > also, what is the best way to blow away a LDAP database on a machine?
> > >
> > > also, i'm using ldbm.
> > > thanks everyone!
> > >
> > > Ron McKown
> > > rmckown@envenergy.com
> > >
> > >
> > >
> > >
> > >
> >
>
> --
> Frank Swasey                    | http://www.uvm.edu/~fcs
> Systems Programmer              | Always remember: You are UNIQUE,
> University of Vermont           |    just like everyone else.
>                     === God Bless Us All ===
>
>