Here, we will introduce the general process of modifying the default mysql password of xampp by using phpmyadmin of xampp to change the mysql password. Then, we will change the phpmyadmin password in xampp, in this way, the default mysql password is completely modified.
Rough Process
Set Password in mysql open IE enter URL localhostphpadmin, click the user to see a root user, pull down, find the place to change the password, enter the password, and perform the operation, finally, go to your xampp installation directory and find the phpadmin folder. inc. after the PHP file is opened, find the mysql configuration and change config to cookie. Set the password to the password you just set.
Method
Enter http: // localhost/phpmyamdin in the browser address to enter the Database Control Panel, and select the database name as mysql. The user table is displayed, the password of the two root users is empty.
You can manually edit the password of the root user in the database. Click "edit" or "edit" to edit the password. For example, if the password is 123456, enter "* 6BB4837EB74329105EE4568DDA7DC67ED2CA2AD9" (excluding quotation marks)
As shown in figure
If you want to change the password to another one, you can directly execute the SQL statement in the west and change new_password to your own password:
1 |
UPDATE user SET password=PASSWORD( 'new_password' ) WHERE user= 'root' ; |
In addition, since the mysql root User password has been modified, the corresponding password configuration in phpmyadmin should also be modified. Find the configuration file, as shown in my
F: xamppphpMyAdminconfig. inc. php
Find the following code:
The Code is as follows: |
Copy code |
Authentication type and info */$ cfg ['servers'] [$ I] ['auth _ type'] = 'Config'; $ cfg ['servers'] [$ I] ['user'] = 'Root'; $ cfg ['servers'] [$ I] ['Password'] = ''; $ Cfg ['servers'] [$ I] ['extension'] = 'Mysql'; $ cfg ['servers'] [$ I] ['allownopassword'] = True; |
Change
The Code is as follows: |
Copy code |
Authentication type and info */$ cfg ['servers'] [$ I] ['auth _ type'] = 'Config'; $ cfg ['servers'] [$ I] ['user'] = 'Root'; $ cfg ['servers'] [$ I] ['Password'] = '000000'; $ cfg ['servers'] [$ I] ['extension'] = 'Mysql'; $ cfg ['servers'] [$ I] ['allownopassword'] = True;
|
In this case, you need to restart phpmyadmin.