Skip to content

Latest commit

 

History

History
32 lines (20 loc) · 557 Bytes

21.change-mysql-user-password.md

File metadata and controls

32 lines (20 loc) · 557 Bytes

Change MySQL user password

  • Login to MySQL as Root User

    mysql -u root -p
  • Change User Password

    • Syntax:-

      ALTER USER <user_name>@'localhost' IDENTIFIED WITH caching_sha2_password by <user_password>;
    • Example:-

      ALTER USER 'root'@'localhost' IDENTIFIED WITH caching_sha2_password by 'Hello123456#';
  • Exit from MySQL

    exit

Reference Links