MySQL: ERROR 1045 Access denied for user ‘root’@'localhost’ (using password: YES)

Posted on September 11, 2009. Filed under: MyWay, Technology | Tags: |

This error message indicates that the MySQL database is not set to receive a root connection from localhost, which is very hilarious issue. The only way I can fix this issue is by resetting the root permission of the MySQL database. So, the answer to that how I do that is at this page.

root@ubuntu:/# ps -ef | grep mysql
root     10993     1  0 Jun03 ?        00:00:04 /bin/sh /usr/bin/mysqld_safe
root     26946 26932  0 21:14 pts/0    00:00:00 grep mysql
root@ubuntu:/# kill -9 10993

Create a mysql-init file, containing these following lines.

UPDATE mysql.user SET Password=PASSWORD('MyNewPass') WHERE User='root';
FLUSH PRIVILEGES;

And then run the mysql with the mysql-init file.

root@ubuntu:/# mysqld_safe --init-file=/home/xxxxx/mysql-init &
[1] 26953

Now the second question is why this happens? I don’t understand why…


Read Full Post | Make a Comment ( None so far )

Recently on Craeser...

CrunchPad: What makes it so special?

Posted on July 6, 2009. Filed under: Technology | Tags: |

HP-UX: Free Software and wget Installation with Proxy

Posted on July 6, 2009. Filed under: MyWay, Technology | Tags: , , |

Javascript: Element setAttribute in MSIE

Posted on June 4, 2009. Filed under: MyWay, Technology | Tags: |

DynDNS: Wildcard No More

Posted on June 4, 2009. Filed under: General | Tags: |

HP-UX: `swlist` security check failed unexpectedly due to missing nsswitch.conf

Posted on May 29, 2009. Filed under: Technology | Tags: |

HP-UX: Expands logical volume size using SAM

Posted on May 21, 2009. Filed under: Technology | Tags: |

RHEL: Logical Volume Management

Posted on May 20, 2009. Filed under: Technology | Tags: , |

Java: Parse using regular expression

Posted on May 20, 2009. Filed under: Technology | Tags: |

Visual Studio: Finds exported functions, variables and classes in a DLL

Posted on May 20, 2009. Filed under: Technology | Tags: |

Outlook: Compose HTML e-mail

Posted on May 20, 2009. Filed under: MyWay, Technology | Tags: |

Liked it here?
Why not try sites on the blogroll...