views:

24

answers:

3

I'm not sure if this will make sense, but I'll give it a shot.

My hard drive went down and I had to reinstall the os along with all my webserver configuration,etc. I kept a backup of the mysql database, but it doesn't contain all the tables...I added a couple tables after my last backup.

I have access to the hard drive and the directory where the mysql data files are stored from the failed hard drive, but I don't know how to retrieve the data into my new mysql database. Is it even possible to get the raw data files from mysql and load them into a different instance? I'd even be happy if there was some way for phpmyadmin to show the data files, then I could dump out to a backup txt file, and reload them into my new configuration.

Any help will be appreciated. thanks.

+1  A: 

The datafiles should be compatible - you can copy the data directory to ubuntu, and edit the /etc/mysql/my.cnf to point to the new directory.

The only catch might be where ubuntu being case sensitive effects the tables.

Adam
what is ubuntu? I originally installed MySQL directly, but someone told me about XAMPP so this time I used that for the installation...I'm assuming ubuntu is like xampp...i'll look for the directory u pointed out.
Ronedog
Oops, thought I read that you had installed linux (ubuntu) and were moving your data across. Sorry about your drive!
Adam
+1  A: 

Although not recommended or reliable, it is possible to simply copy the data without using mysqldump. It might help if MySQL was shut down in a controlled manner (which does not appear to be the case) and the source and target environments are as similar as possible in terms of lib and MySQL versions.

Tomislav Nakic-Alfirevic
A: 

well, bad news...I can't access the drive anymore. As I tried to copy the files the drive went totally down. So, I'll just redo the couple tables. Thanks for your help anyway.

Ronedog
Sorry to hear that, but from your reaction I gather it's not too bad. :)
Tomislav Nakic-Alfirevic