PHP
[Laravel] MySQL 8.X 버전 인증 오류 (authentication method unknown to the client)
sjwiq200
2020. 2. 11. 23:51
728x90
반응형
다른 오류로 brew upgrade를 하게 돼서 mysql 버전이 8.x 버전으로 업그레이드가 됬습니다.. ㅠ
아래에서 보이는 바와 같이 인증관련 문제가 발생했다고 로그가 찍혔는데요!
# 스택오버플로우에서 간단한 해결책을 찾았습니다
# 이 문제는 Mysql의 기본 인증 플러그인 지원이 변경 되었기 때문이라고 하네요~!
PHP with MySQL 8.0+ error: The server requested authentication method unknown to the client
I'm running MySQL version 8 on PHP 7.0. I'm getting the following error when I try to connect to my database from PHP: Connect Error: SQLSTATE[HY000] [2054] The server requested authentication ...
stackoverflow.com
다음과 같이 해당 계정의 비밀번호를 변경해주면 됩니다.
ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY 'password';
728x90
반응형