#1045 - Access denied for user 'pmausr'@'localhost' (using password: YES)

来源:百度知道 编辑:UC知道 时间:2024/09/22 05:43:36
我用的是phpMyAdmin 2.9.2 ,进去用默认账户root登陆,密码就是安装MySQL时输入的密码。登陆时显示错误
#1045 - Access denied for user 'pmausr'@'localhost' (using password: YES)
================================
下面是config.inc.php文件的内容:
<?php

/* $Id: config.sample.inc.php 9675 2006-11-03 09:06:06Z nijel $ */
// vim: expandtab sw=4 ts=4 sts=4:

/**
* phpMyAdmin sample configuration, you can use it as base for
* 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>.
*/

/*
* This is needed for cookie based authentication to encrypt password in
* cookie
*/
$cfg['blowfish_secret'] = 'zhuoran'; /* YOU MUST FILL IN THIS FOR COOKIE AUTH! */

/*
* Servers configuration

1、在phpmyadmin的登陆页面中,先选一下繁体字,然后再选简体中文,然后再登陆

2、在 MySQL的命令行中更新一下密码
更新密码的方法
update user set password=password('原密码') where user='用户名';

3、在config.inc.php 文件中

搜索「$cfg['Servers'][$i]['auth_type'] 后面的登录方式改成cookie如:
「$cfg['Servers'][$i]['auth_type'] = 'cookie';」

若不成功,还是得试试
在config.inc.php 文件中

搜索「$cfg['Servers'][$i]['auth_type'] = 'cookie';」,改成「$cfg['Servers'][$i]['auth_type'] = 'http';」

搜索「$cfg['Servers'][$i]['controluser'] = 'pmausr';」,改成「$cfg['Servers'][$i]['controluser'] = 'root';」

搜索「$cfg['Servers'][$i]['controlpass'] = 'pmapass';」,改成「$cfg['Servers'][$i]['controlpass'] = 'MYSQL的密码;」