MySQL Change password

Source: Internet
Author: User

1: First, the MySQL service starts

2: Open dos as follows, Win7 system

Microsoft Windows [version 6.1.7601]
Copyright (c) Microsoft Corporation. All rights reserved.

C:\users\administrator>CD C:\Program Files (x86) \mysql\mysql Server 7.0\bin------into the bin directory of the database installation directory

C:\Program Files (x86) \mysql\mysql Server 7.0\bin>mysql-uroot-p-------------Open MySQL
Enter Password: ****-------automatically prompt for a password
Welcome to the MySQL Monitor. Commands End With; or \g.
Your MySQL Connection ID is 2
Server VERSION:5.1.39-NDB-7.0.9-CLUSTER-GPL MySQL Cluster Server (GPL)

Type ' help ', ' or ' \h ' for help. Type ' \c ' to clear the current input statement. ---------successfully landed

Mysql>Set password for [email protected] = password (' test ');-------Change Password
Query OK, 0 rows Affected (0.00 sec)

Mysql>Exit----exit
Bye

C:\Program Files (x86) \mysql\mysql Server 7.0\bin>mysql-uroot-p-----Sign in again
Enter Password: ****-----Enter the original password
Error 1045 (28000): Access denied for user ' root ' @ ' localhost ' (using password:y----------------original password error not logged on
ES)

C:\Program Files (x86) \mysql\mysql Server 7.0\bin>mysql-uroot-p-------try to sign in again
Enter Password:****------Enter a new password
Welcome to the MySQL Monitor. Commands End With; or \g.
Your MySQL Connection ID is 4
Server VERSION:5.1.39-NDB-7.0.9-CLUSTER-GPL MySQL Cluster Server (GPL)

Type ' help ', ' or ' \h ' for help. Type ' \c ' to clear the current input statement.

Mysql>-------successfully landed, the password was changed

MySQL Change password

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.