#1045-Access denied for user 'root' @ 'localhost' (using password: Yes

Source: Internet
Author: User

I have found many methods on the Internet to solve this problem.

I use php-4.4.1 + mysql-4.0.26 + Windows2000 Professional Build Environment

Phpmyadmin2.11.4.

After the installation is complete, it is installed in the web directory.Discuz!6.0.0 is successful.

Then, after phpmyadmin2.11.4 is installed, the following error occurs: Problem example: {MySQL #1045-Access denied for user 'root' @ 'localhost' (using password: No )}

Install phpmyadmin2.11.4. You can download and decompress it directly in the web directory. The directory of my 2000 system is C:/inetpub/wwwroot/phpMyAdmin.

The most common method on the internet is fromPHPmyAdmin/Find the config. Default. php file in the libraries directory and copy it to the root directory.Change the name to config. Inc. php in phpMyAdmin and modify the content.

But it is not required in phpmyadmin2.11.4. You only need to find the config. sample. Inc. php file in the root directory and copy the content to the config. Inc. php file. Config. Inc. php should be placed in the root directory.

Modify the content as follows: (only modify the red part)

<? PHP
/* VIM: Set expandtab Sw = 4 ts = 4 STS = 4 :*/
/**
* PhpMyAdmin sample configuration, you can use it as base
* Manual configuration. For easier setup you can use scripts/setup. php
*
* All directives are explained in documentation.html and on phpMyAdmin
* Wiki <Http://wiki.cihar.com>.
*
* @ Version $ ID: config. sample. Inc. php 10142 2007-03-20 10: 32: 13z cybot_tm $
*/

/*
* This is needed for Cookie based authentication to encrypt password in
* Cookie
*/
$ Cfg ['blowfish _ secret'] = '000000 ';/* You must fill in this for Cookie auth! */
// This sentence is not required for comments. The above 2156 is a random value.

/*
* Servers Configuration
*/
$ I = 0;

/*
* First Server
*/
$ I ++;
/* Authentication type */
$ Cfg ['servers'] [$ I] ['auth _ type'] = 'cooker ';
/* Server parameters */
$ Cfg ['servers'] [$ I] ['host'] = 'localhost ';
$ Cfg ['servers'] [$ I] ['connect _ type'] = 'tcp ';
$ Cfg ['servers'] [$ I] ['compus'] = false;
/* Select mysqli if your server has it */
$ Cfg ['servers'] [$ I] ['extension'] = 'mysql ';
/* User for advanced features */
$ Cfg ['servers'] [$ I] ['controluser'] = 'root ';
$ Cfg ['servers'] [$ I] ['controlpass'] = '20140901 ';
/* Advanced phpMyAdmin features */
// $ Cfg ['servers'] [$ I] ['pmadb'] = 'phpmyadmin ';
// $ Cfg ['servers'] [$ I] ['bookmarktable'] = 'pma _ bookmark ';
// $ Cfg ['servers'] [$ I] ['relation'] = 'pma _ relation ';
// $ Cfg ['servers'] [$ I] ['table _ info'] = 'pma _ table_info ';
// $ Cfg ['servers'] [$ I] ['table _ coords '] = 'pma _ table_coords ';
// $ Cfg ['servers'] [$ I] ['pdf _ page'] = 'pma _ pdf_pages ';
// $ Cfg ['servers'] [$ I] ['column _ info'] = 'pma _ column_info ';
// $ Cfg ['servers'] [$ I] ['History '] = 'pma _ history ';
// $ Cfg ['servers'] [$ I] ['designer _ coords '] = 'pma _ designer_coords ';

/*
* End of servers Configuration
*/

/*
* Directories for saving/loading files from server
*/
$ Cfg ['uploaddir'] = '';
$ Cfg ['savedir'] = '';

?>

After the basic work is completed, an error such as the question will be prompted when you try to open it.
The method is inC:/inetpub/wwwroot/Create a folder under the directory (for example, PMA)

ThenPhpMyAdminDrag the folder to the PMA directory.

The accessed directory should be http: // localhost/PMA/PHPmyAdmin/index. php.

If the previous step$ Cfg ['blowfish _ secret'] = '000000 ';If no value is set, the system will prompt the error message "the configuration file now requires a top secret phrase password (blowfish_secret )"

If you forget the settings, I will try again. I am also a newbie. I just started learning PHP. Inaccurate descriptions are often included.

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.