Solution For “No tables found in database” Mysql Error In phpMyAdmin

↓ Sponsored Links / Home » Web Hosting

Are you having the “No tables found in database” error where accessing them via phpmyadmin is not possible while the websites or blogs runs perfectly without any problem? The pulldown correctly lists the number of tables next to the database name [example: “blogA (13)” and blogB (18)] in the pulldown.

Recommended Reading: 7 Must Use SQL Queries To Clean And Optimize WordPress MySQL Database

Solution For

If your phpMyAdmin no longer sees any tables in any of your local databases, that is because permissions change away from mysql.mysql on any database directory under /var/lib/mysql to, say, root.root (most probably).

Long story short, you will have to change the owner from root.root to mysql.mysql, to do this, you’ll need root access and putty. Key in this command:

chown -R mysql.mysql /var/lib/mysql/*

This will most probably solve your ‘No Table Found’ problem, it took me much searching and trial and error to resolve this issue, not to mention growing a really long beard while waiting for your web hosting to figure out the problem, let alone replying you. Cheers.

10 comments on “Solution For “No tables found in database” Mysql Error In phpMyAdmin

  1. Gravatar
    xsor October 25, 2010 at 6:50 am [ Reply ]

    what about mySQL under windows 7 ?

  2. Gravatar
    Stuart February 22, 2012 at 4:12 pm [ Reply ]

    I’m having this exact problem on my MAMP server but I have no clue how to sort it. Can you explain to me how you change the permissions to mysql.mysql as i’m a super newb. Please explain it as you would to a child ;)


    • Gravatar
      GeckoFly February 22, 2012 at 4:39 pm [ Reply ]

      @Stuart – Do you have access to root? Access your server as ‘root’ user and type the command line as shown above. That’s all.

  3. Gravatar
    Stuart February 22, 2012 at 11:12 pm [ Reply ]

    It’s ok now, I found an alternative fix! I downloaded a ep plugin called lime export and exported my tables trough wp to an SQL file. Sites now live!

  4. Gravatar
    Ciskut June 3, 2012 at 5:04 am [ Reply ]

    Hi there,

    I followerd the instructions (changed the password from ‘root’ to mysql) and now I lost access to MAMP completely.

    Please can you help me to fix it and get everything back?
    I’m no expert so if you could give me step-by-step instructions it would great…


    • Gravatar
      GeckoFly June 3, 2012 at 1:17 pm [ Reply ]


      I think you’re supposed to change the permission to ‘root’, not the password to ‘root’

  5. Gravatar
    Ciskut June 3, 2012 at 9:12 pm [ Reply ]

    Hi see…well now I know!
    Thank you GeckoFly for your feedback.

  6. Gravatar
    jo September 3, 2012 at 6:53 pm [ Reply ]

    i try to type the command line..

    chown -R mysql.mysql /var/lib/mysql/*

    but still can’t fixed the priblem..please advise

    • Gravatar
      GeckoFly September 4, 2012 at 12:44 am [ Reply ]


      Maybe the location of your MySQL is different from mine, I suspect it is not under the directory /var/lib/mysql/

      Check with your web hosting company on the directory

  7. Gravatar
    Henk January 4, 2013 at 4:02 am [ Reply ]


    I had no mysqldump, only a copy of the files in /var/lib/mysql.
    regranting root.root worked for me.

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>