List:General Discussion« Previous MessageNext Message »
From:Neil Curri Date:July 19 2000 1:23pm
Subject:Re: mysql root password problem
View as plain text  
Thanks, Gents.

> You have to FLUSH PRIVILEGES *before* the GRANT command.  (Subject of a
> recent thread on this list.)

I searched recent archives with "root" and "password" as key words. Will
search more thoroughly next time. I made a silly mistake, so hopefully
my blundering will serve as an example for other newbies:

Issuing FLUSH PRIVILEGES *before" issuing grant definitely did it. What
started this though, was that I originally updated the User table in the
mysql database directly by using UPDATE statements - the new root
password that was simply entered as text, not encrypted. Here's my
mistake -- The New Riders' MySQL (Paul DuBois) book states:

--
For any version of MySQL, you can use the mysql program and update the
user grant table in the mysql database directly:

mysql> UPDATE user SET Password=PASSWORD("your password") where
User="root";
--

But I simply issued:
mysql> UPDATE user SET Password="my password" where User="root";

So my error was that I simply entered a text password. So PASSWORD("my
password") must take care of the password encryption same as the GRANT
statement, right? 

However, I followed your suggestions and used the GRANT statement (after
issuing FLUSH PRIVILEGES of course) -- it encrypted my password, and now
I can get in with new password and all's well. Thanks so much.
Thread
mysql root password problemNeil Curri17 Jul
  • RE: mysql root password problemRobert Goff17 Jul
    • Re: mysql root password problemNeil Curri17 Jul
Re: mysql root password problemNeil Curri19 Jul
Re: mysql root password problemcurt19 Jul
Re: mysql root password problemNeil Curri19 Jul
  • RE: mysql root password problemRobert Goff19 Jul
    • Re: mysql root password problemNeil Curri19 Jul
      • RE: mysql root password problemRobert Goff19 Jul
Re: mysql root password problemcurt19 Jul
  • RE: mysql root password problemRobert Goff19 Jul
Re: mysql root password problemColin Faber19 Jul