Whenever I try to Grant Privileges as root@localhost, it says permission denied (using password=Yes).
My root user is the one that I am logged in as. I verify this by select user();
It responds with 'root'@'localhost'.
I have also checked out this stack overflow post which seems to be the same issue:
and this one
I am having no luck. If I Show GRANTS;, It lists all GRANT privileges: SELECT, Insert, Update, DELETE, CREATE, DROP, etc.
-
How do I make sure that ROOT has GRANT option itself?
-
Why would my root user not have all privileges? I am using mysql version: 5.5.38-0+wheezy1 on Debian.
Best Answer
I have dealt with this issue before.
When you ran
you should have gotten 42. That's how many columns MySQL 5.5 has for
mysql.user
. Since you got 39, that means you must have upgraded from MySQL 5.1. That has 39 columns.I wrote an earlier post about the number of columns in
mysql.user
in different versions : MySQL service stops after trying to grant privileges to a userHere is the post where I dealt with this : mysql: Restore All privileges to admin user
Hopefully you could run
to realign
mysql.user
and have it autofill missing permissions withY
.Give it a Try !!!
If you want to try to fix the mysql.user manually, here are the steps:
That's it !!!