Koozali.org: home of the SME Server

restore databases (Backup2) 911

CKConsulting

restore databases (Backup2) 911
« on: December 04, 2006, 04:32:30 PM »
Good Morning,
Long story on how I got here but....  I was trying to restore /opt/jinzora with Backup2 usb 911.  Everything seemed fine, I rebooted and noticed it didn't fix my issue.  Then the trouble started.  After uninstalled and reinstalling myphpadmin.  I was able to view mysql and my databases are there but there are no tables or data in them???

Is there a way to restore databases?


Rick

Offline Daniel B.

  • *
  • 1,700
  • +0/-0
    • Firewall Services, la sécurité des réseaux
restore databases (Backup2) 911
« Reply #1 on: December 04, 2006, 05:36:16 PM »
All your databases are saved with the signal-event pre-backup. They are stored in the file /home/e-smith/db/mysql/mysql.dump. To restore them, just type (as root)
Code: [Select]
mysql < /home/e-smith/db/mysql/mysql.dump

This command will restore all your mysql database as they were during the backup.
C'est la fin du monde !!! :lol:

CKConsulting

restore databases (Backup2) 911
« Reply #2 on: December 04, 2006, 06:17:32 PM »
Thank you!!

mackayr

restore databases (Backup2) 911
« Reply #3 on: December 12, 2006, 07:45:06 PM »
Interesting.  This is precisely the issue I'm dealing with, but there is no dump in that directly.  Fortunately for me, I'm in the midst of transferring from one server to another, and my previous server is still up and running.  Two questions:

1) I've used backup2.  Is there any reason this dump wouldn't have occurred.  Is there somewhere in the logs I can check and see what went wrong (and why)?

2) What's the easiest way to get my databases over to the new server.

Thanks,

Rob

CKConsulting

restore databases (Backup2) 911
« Reply #4 on: December 12, 2006, 08:14:15 PM »
I haven't had time to look into this but I restored another file/dir on the server and it dumped all the mysql tables and data.  Databases were still listed but no data in them.  Lucky this was my home server which was just a music database, xoops, and joomla websites.  I tested a couple more restores and it wiped the mysql data again.  Horde database restores it self the the others were toast.

Rick

Offline dmay

  • *
  • 450
  • +0/-0
    • http://myezserver.com
restore databases (Backup2) 911
« Reply #5 on: December 12, 2006, 09:40:16 PM »
You should not issue this command:

mysql < /home/e-smith/db/mysql/mysql.dump

It will break your mysql root password. One fix is reported here:

http://bugs.contribs.org/show_bug.cgi?id=778

The proper way to restore your entire mysql db is scripted into the backup2-restore action which when properly executed runs the built in pre-restore event followed by your manual post-upgrade;reboot.

If your databases are appearing to be only partially restored you may be encountering this mysql bug I reported:

http://bugs.contribs.org/show_bug.cgi?id=2149

Darrell