Phpmyadmin-PHP source code

Source: Internet
Author: User
Tags mysql login
In phpmyadmin, password settings are divided into three modes: cookie authorization mode, config authorization mode, and http Authorization mode. The following describes how to configure these three modes. In phpmyadmin, password settings are divided into three modes: cookie authorization mode, config authorization mode, and http Authorization mode. The following describes how to configure these three modes.

Script ec (2); script


You can download phpmyadmin from the official website, and then modify config. cfg. php in the directory.

1. Use cookie authorization Mode

Change 'auth _ type' to 'cooker', and then modify 'blowfish _ secret' to use an arbitrary string as the cookie's encrypted string. If no encryption key exists, the system displays "the configuration file currently requires a top secret phrase password (blowfish_secret)". The configuration file is as follows:

$ Cfg ['servers'] [$ I] ['auth _ type'] = 'cooker ';

$ Cfg ['blowfish _ secret'] = '44e2f5aece2855. 8080 ';

After the modification is completed, enter the logon window

Web login page in http Authorization Mode

Ii. Use the config authorization Mode

Config requires these parameters:

$ Cfg ['servers'] [$ I] ['auth _ type'] = 'config'; // authorization Mode

$ Cfg ['servers'] [$ I] ['user'] = 'root'; // mysql Login user

$ Cfg ['servers'] [$ I] ['Password'] = '000000'; // mysql Login User password

3. Use http Authorization Mode

$ Cfg ['servers'] [$ I] ['auth _ type'] = 'http ';

Http Authorization mode logon window

Note: If the mysql server uses version 4.1 or later and the client connection uses the mysql4.1 version, use the OLD_PASSWORD function when setting the password for the user. For example:

Mysql> set password = OLD_PASSWORD ('20140901 ')

Mysql>/G

What should I do if I forget my phpmyadmin password?


1. Disable the mysql service.

# Service mysql stop


If an error message such as mysql: unrecognized service is displayed.

First, check for mysql. server and use: find/-name "mysql. server"


Run the/usr/local/mysql/share/mysql. server stop command to disable mysql.


2. Start mysql in security mode to skip the authorization table.

First, check the mysqld_safe program. You can use the find/-name "mysqld_safe" command to find the program. It is in the mysql installation directory by default.

# Find/-name "mysqld_safe"


Start mysql in security mode to skip the authorization table


3. log on to mysql with the root account and change the password to re-authorize

Create a connection to log on to the ECS


1) first enter the mysql-u root command to log on to mysql

2) Enter update mysql. user set password = PASSWORD ('000000') where User = 'root'; update mysql password to 123456789

3) quit mysql

4. Restart the mysql service.


1) killall mysqld ends all mysql Processes

2) service mysql start mysql

3) Press enter from mysql-u root-p and enter the password, which is the mysql password you just reset.

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.