#1045 - Access denied for user 'root'@'localhost' (using password: YES)

前端 未结 23 3426
刺人心
刺人心 2020-11-30 01:39

This might seem redundant but I was unable to find a correct solution.

I was unable to login to mysql using the mysql console.It is asking for a password and I have

23条回答
  •  旧巷少年郎
    2020-11-30 02:32

    This worked for me. In your config file

    $cfg['Servers']['$i']['password'] = 'yourpassword';
    

    In your mysql shell, login as root

    mysql -u root
    

    change your password or update if you've forgotten the old one

    UPDATE mysql.user SET Password=PASSWORD('yourpassword') WHERE User='root';
    

    stop and restart your mysql server from the xampp control panel. phpmyadmin can login to see your databases

提交回复
热议问题