I copy my database files from windows


into my ubuntu


Folders of my database_name and ibdata1, ib_logfile0, ib_logfile1 files. Now my all databases and tables are visible into phpmyadmin but when selecting any table, it shows table doesn't exist

How to get back my all the data

Here is the screenshot.

  • First I would check if the file system permissions in /var/lib/mysql/ are correct for the mysql system user to access your data – HBruijn Feb 22 '17 at 11:14
  • I have run this command. $ sudo chown -R mysql:mysql /var/lib/mysql/ – Siraj Alam Feb 22 '17 at 11:15
  • Have you considered dumping the database using mysql tooling, rather than copying the folder structure? It sounds like you may not have all the files needed, are there any errors (other than "table doesn't exist") in your mysql logs? Also, a silly question, but did you restart mysql after copying and chown'ing the files? – iwaseatenbyagrue Mar 6 '17 at 8:44

After Googling a lot I found the answer.

Restart your mysql

sudo mysql stop

sudo mysql start

Refresh the phpmyadmin page

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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