[K12OSN] Power outage - ldap stopped working
David Trask
dtrask at vcsvikings.org
Mon Sep 19 14:53:27 UTC 2005
Tom....when I was on your server the other day I made a backup of the ldap
database....I think it was in /root and it's something like "mybackup"?
To restore...simply do
slapadd -l "filename" (where filename is the name of the backup I made)
Also...before doing that....make a backup of /home and put it somewhere on
the hard drive so folks don't lose their stuff in the event that you need
to run the smbldap-installer again and recreate the users by running the
create-user script again. To do this..run something like...
cd /home
tar -czvf home-backup.tgz *
This will backup the contents of /home into a file called home-backup.tgz
(and it preserves permissions)....then
cd /home (you should already be there)
mv home-backup.tgz /root (or anywhere else you want for safekeeping)
Now try the following....
First make sure nscd is off
service nscd status (if not then run service nscd stop)
service ldap restart (if it fails to start...quit here)
service smb restart
If all fails...go to next step...
service smb stop
service ldap stop
rerun the smbldap installer...be sure to use the exact same passwords and
stuff you used before
Then reboot
Next...
service nscd stop
chkconfig --level 12345 nscd off
service smb stop
service ldap stop
run
slapadd -l "filename" (where filename is the name of the backup I made)
Now....if you have permission issues...we can fix that quickly with a
script like this...
in the terminal as root....
gedit fix-perms
then paste this into it
!#/bin/bash
for x in `ls /home`; do
echo "Doing $x ..."
cd /home/{$x}
chown -R ${x}:513 *
echo "I have changed the permissions for ${x}
done
Then close gedit and then make the file executable
chmod a+x fix-perms
to run it simply do...
. fix-perms
Keep me posted!
"Support list for opensource software in schools." <k12osn at redhat.com> on
Mon Sep 19 2005 at 10:05 +0000 wrote:
>Help!!
>
>We had a power outage and the server went down. Now ldap won't start
>back up. I am running FC3 (from the k12ltsp4.2.1 disks). I had the
>system check the disks at startup, and it found and corrected some
>problems. But ldap still won't go. Slapcat replies with "Slap_startup
>failed".
>
>Is there a utility for checking/repairing/restoring the ldap database?
>
>Thanks!!!
>
>Tom
David N. Trask
Technology Teacher/Coordinator
Vassalboro Community School
dtrask at vcsvikings.org
(207)923-3100
More information about the K12OSN
mailing list