The newer versions of MySQL default to caching_sha2_password. If you want to disable it then follow below steps
- Login in to your MYSQL console as root user like below.
eg mysql -u YOUR_ROOT_USER_NAME -p YOUR_ROOT_USER_PASSWORD
- Then execute the command by replacing
YOUR_ROOT_USER_NAME
and YOUR_ROOT_USER_PASSWORD
ALTER USER 'YOUR_ROOT_USER_NAME'@'localhost' IDENTIFIED WITH
mysql_native_password BY 'YOUR_ROOT_USER_PASSWORD'
;
You will no longer get any 'caching_sha2_password
' exception while connecting for any client after this.