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

Re: server restart - lost data?



thank you for your response Jon.

i have couple of db_recover commands on my system.

db_recover
db2_recover
db33_recover
db41_recover

I don't know which one to use. I used first one and got error. then i tried
all others and got errors too. i did not use with -v option. Also i don't
remember the errors.

As you suggested backing up using slapcat seems to be a good idea.

thanks,
shashank


Jon Roberts (jon@jonanddeb.net) wrote:
>
> Shashank Agrawal wrote:
> > after i posted my first message to this list, i ran db_recover in the ldap
> > data directory and it looked like it wiped out the whole database. so i have
> > to go back and recover the database from backup.
>
> Yikes. I haven't had that happen. What exactly do you mean by "wiped out
> the whole database"? Did the .bdb data files disappear? Did you get an
> error response code from db_recover? Did you try db_recover in verbose
> mode (-v)? What was the behavior of slapd afterwards?
>
> > But still i am wondering how can i recover those 200 some entires that were
> > added in ldap, which were not written to the db, and which were lost after
> > server crash. I can manually add them again if recover is not possible, but
> > how would i prevent such thing from happening again.
>
> Same as I said before. If db_recover failed you, I would imagine your db
> was otherwise corrupted first. I really don't know, though.
>
> A good safeguard is to slapcat the db out to a backup file periodically.
> With your version of OpenLDAP, you can do that without shutting slapd down.
>
> > thank you so much.
>
> Sorry I couldn't help more.
>
> Jon Roberts
> www.mentata.com
>