Click here to Skip to main content
15,885,216 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hello! I have a problem with a MySQL database that I haven’t been able to solve no matter how much I tried, either with internet guides or with free tools. I really don’t want to pay hundreds of dollars to a company so please, if anyone knows of a solution, help me because I’m desperate.

I was running XAMPP 7.1.22 where I had said database and I decided to install XAMPP 7.2.10 without backing up the database. After that, the site wasn’t working so I figured the problem was the database. And indeed PHPMyAdmin wouldn’t recognize it. I reinstalled the previous version of XAMPP and the database was there but unfortunately I could only see the tables. The tables themselves were empty though. So no dump procedure worked and neither the site. Now all I have left is the folder with the database which contains all the .frm and the .ibd files, an .opt file, a .myd file and a .myi file. I also have the ibdata1 file. 

Any ideas or suggestions? Thank you very much for your time.


What I have tried:

I haven’t been able to solve no matter how much I tried, either with internet guides or with free tools.
Posted
Updated 19-Oct-18 19:37pm

First of stopped my MySQL service using XAMPP’s

then move your files ib* files and the folder containing the *.frm files to the local mysql data folder
(C:\Program Files\xampp\mysql\data)

then edit my.cnf
(located in C:\Program Files\xampp\mysql\bin)
and made the following changes (starting at line 66 or check your file for line ):
OLD:
skip-innodb
#innodb_data_home_dir = C:/Program Files/xampp/mysql/data/
#innodb_data_file_path = ibdata1:10M:autoextend
#innodb_log_group_home_dir = C:/Program Files/xampp/mysql/data/
#innodb_log_arch_dir = C:/Program Files/xampp/mysql/data/
#set-variable = innodb_buffer_pool_size=16M
#set-variable = innodb_additional_mem_pool_size=2M
#set-variable = innodb_log_file_size=5M
#set-variable = innodb_log_buffer_size=8M
#innodb_flush_log_at_trx_commit=1
#set-variable = innodb_lock_wait_timeout=5

#skip-innodb
innodb_data_home_dir = C:/Program Files/xampp/mysql/data/
innodb_data_file_path = ibdata1:10M:autoextend
innodb_log_group_home_dir = C:/Program Files/xampp/mysql/data/
innodb_log_arch_dir = C:/Program Files/xampp/mysql/data/
set-variable = innodb_buffer_pool_size=16M
set-variable = innodb_additional_mem_pool_size=2M
set-variable = innodb_log_file_size=170M
set-variable = innodb_log_buffer_size=8M
innodb_flush_log_at_trx_commit=1
set-variable = innodb_lock_wait_timeout=50

set innodb_log_file_size to the actual size of my log file then edited the XAMPP batch file that starts the mysql service
(C:\Program Files\xampp\mysql_start.bat)

add –innodb_force_recovery=6 to the end of the call to mysqld.
So line 8 of that file now
mysql\bin\mysqld –defaults-file=mysql\bin\my.cnf –standalone –console –innodb_force_recovery=6
 
Share this answer
 
Comments
Thodorompalos 13-Oct-18 0:22am    
Hello. Thank you for your answer but after I follow the steps you provided, MySQL doesn't start. In addition, when you say the actual size of the log file, you mean the standard file of XAMPP or the old one that went with the database? Because I tried that too and I didn't work as well. Anyway thank you again and if you can help me further I'd appreciate it.
Well after waiting and trying a lot, I decided to roll back the site and add the missing content again. Thanks for your time.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900