List:General Discussion« Previous MessageNext Message »
From:Todd Lyons Date:August 26 2009 2:36am
Subject:Re: recovery help needed
View as plain text  
>> On Wed, Aug 26, 2009 at 02:12, Joe<>
> wrote:
>> > We have an inaccessible MySQL v5.0.45 DB (w/Innodb) we
>> > really need some help regaining access to.  While attempting
>> > to adjust/add remote user access, we accidentally did the
>> > following:
>> >
>> >  use mysql;
>> >  update user set host = 'SomeBogusIP' where user = 'root';
>> > Now, we can't get into the DB to fix it:
>> > # mysql test
>> > ERROR 1044 (42000): Access denied for user ''@'localhost' to
>> > database 'test'

So connect to it from somewhere other than localhost. :-)
Specifically from the bogus IP you set it to.

Let's say you used the bogus IP of
1. Give the mysql server the IP and a netmask
2. On some other machine on the same LAN, give it the bogus IP with
the same netmask.
3. No need to worry about routes, it's on the same LAN.
4. On the other machine, connect using 'mysql -h10.200.100.10 -uroot
-p'.  When you enter the correct password, it should let you in.

* I don't know if you'll need to restart mysql for it to bind to the
new IP.  I don't think so, but then again I have not tested it.

Regards...      Todd
recovery help neededJoe26 Aug
  • Re: recovery help neededWalter Heck - OlinData.com26 Aug
    • Re: recovery help neededJoe26 Aug
      • Re: recovery help neededTodd Lyons26 Aug
      • Re: recovery help neededMartijn Engler26 Aug
        • Re: recovery help neededprabhat kumar26 Aug
  • Re: recovery help neededCarlos Proal26 Aug