I have a Time Machine backup drive from a MacBook Pro machine I don’t have anymore (technically, I reformatted a while back). It contained a MySQL database installed, managed, and run by my XAMPP for OS X installation (an much older version than the latest).

I’m looking for any and all help recovering that database. Where should I look for what files? How should I recover the data from them?

(Please let me know if I should post this to Stack Overflow instead.)

link|improve this question

You're looking for the Data folder, in which the database file(s) will be stored. If Time Machine ran while the database was in use, there is a chance of corruption due to unwritten pages. You can try pointing your new MySQL instance at the file(s) but there's no guarantee it'll work. – Randolph West Feb 13 '11 at 2:42
@Randolph The only Data folders that appear to be in /Applications/xampp/ are within "pear" and "perl5" and don’t look like they contain database files (unsurprisingly). Should I be looking elsewhere? – Alan H. Feb 13 '11 at 20:43
1  
There should be a data folder for the MySQL installation. If you can't find it, look for a file or folder with the name of the database. – Randolph West Feb 13 '11 at 21:33
feedback

1 Answer

up vote 1 down vote accepted

Success!

Using Back-In-Time, I have copied out an old version of Applications/xampp from the Time Machine backup.

Of note seems to be the folder xamppfiles/var/mysql, which appears to contain folders with names of the databases I had running under XAMPP.

I simply copied the folders corresponding to the databases I wanted to restore to my new machine’s Applications/XAMPP/xamppfiles/var/mysql, restarted MySQL, and was good to go!

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.