how do I reset user "root" password ?
am 13.02.2006 02:12:22 von damontimmMy setup: Mac OS 10.4.4; mysql 4.x ... everything was installed and
working fine for some time. Today, I added drupal to my system and had
to create a new database in mysql -- now I am having some problems. I
will outline the problem, what I have tried to do to fix it, and what I
think caused it. Hope you can help and I am sorry this is long.
The problem: I can't login to mysql anymore with the "root" username
(which is where I have all my database files and tables stored for a
couple wordpress installs, the bbpress, and now the drupal). When I
execute in terminal:
/usr/local/mysql/bin/mysql -u root -p
And then enter my password, I get the following error:
ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using
password: YES)
Attempted solutions: I assumed the password was changed somehow; I
wanted to reset the password for "root". I searched the internet, and
most suggest that I (in summary): kill the mysqld process, then either
find a .pid file for my server and do something with it (but I can't
get in the directory that houses the file) -or- enter mysqld
--skip-grant-tables --user=root after I've killed the mysqld command
again.
In both instances, I am getting permission errors and I can accomplish
neither.
I believe the .pid I need to chanage is housed in my
/usr/local/mysql/data folder, however, I can't get access to the
folder. The permissions are set to have "mysql" be the owner
(drwxrwx---).
I am not a unix wiz, have tried to chmod my way out of it, but no luck.
No matter what I try, I seem to be running into a permissions issue --
how can I reset permissions ?
Why I am being punished: I think this all might have started when I was
setting up the database for drupal, I think I did something to cause a
password change (I ran one set of commands without re-typing "user"
over the template).
I guess I just need a little hand holding.
Thank you!