It depends on what operating system you are running, but you need to kill the MySQL service and relaunch it skipping the grant tables.
On OSX with MAMP
- Shutdown MAMP all together, this will ensure that MySQL is not running
- Then enter the following command to start MySQL with the right permissions
/Applications/MAMP/Library/libexec/mysqld --skip-grant-tables --port=8889 --socket=/Applications/MAMP/tmp/mysql/mysql.sock
- Then launch mysql command line utility to update priviledges
mysql -u root
In *nix:
mysqld --skip-grant-tables
Then run mysql to get into the command prompt
mysql -u root
Once in MySQL Command Line
Once running in skip grant tables mode, you can run a command to update the user privileges.
UPDATE mysql.user SET Grant_priv='Y', Super_priv='Y' WHERE User='root';
FLUSH PRIVILEGES;