[NTLUG:Discuss] MySQL question
rob apodaca
robert.apodaca at attbi.com
Mon Jul 29 13:24:47 CDT 2002
On Mon, 29 Jul 2002 10:45:10 -0500
Bobby Wrenn <bjwrenn at augustmail.com> wrote:
> On Friday 26 July 2002 02:41 pm, you wrote:
> > Try this:
> > $ mysql -u root -p mysql
> > msyql> select User, Password, Host from user;
>
> Did all that and get the following:
> +--------+------------------+-----------------------+
> | user | password | host |
> +--------+------------------+-----------------------+
> | root | 7705896139c3146a | localhost |
> | root | | localhost.localdomain |
> | | | localhost |
> | | | localhost.localdomain |
> | neil | | |
> | neil | 7705896139c3146a | % |
> +--------+------------------+-----------------------+
>
> So, I have more than one root and more than one neil. Is there a way to
> return the mysql database to default install state?
If you installed from rpm, then sure, just uninstall the rpm and re-install.
But, you probably dont need to do that.
Just issue these two sql statements:
$ mysql -u root -p mysql
mysql> DELETE FROM user WHERE User = 'neil';
mysql> GRANT ALL PRIVILEGES ON *.* TO neil at localhost IDENTIFIED BY 'neilspassword' WITH GRANT OPTION;
now user 'neil' is ready to connect from the localhost with whatever password you specified.
More information about the Discuss
mailing list