MySQL Forums
Forum List  »  Newbie

ERROR 1045 (28000): Access denied for user 'root'@'localhost'
Posted by: Sakai Noriko
Date: September 25, 2016 09:50PM

Hi everyone,
I understand that this question may have been discussed previously, but here my case seems just could get over by all the ways I found from previous posts.

OS: Ubuntu 16.04
DB: MySQL 5.1.15

After installed and started mysql service, I could not login with following commands:
mysql -u root -p
mysql -h localhost -u root -p

Following cures I found, I started 'mysqld_safe --user=root --skip-grant-tables &', and did following update to user table:

update user set authentication_string='mypassword'
where user='root'

flush privilegs

However after restarted the service, I still couldn't login with 'root' and kept getting following error:

ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)

Could any one kindly point me to the direction to solve this?


Thanks

Options: ReplyQuote


Subject
Written By
Posted
ERROR 1045 (28000): Access denied for user 'root'@'localhost'
September 25, 2016 09:50PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.