
XAMPP环境下mysql的用户密码修改
点击数:1998 更新时间:2014-04-06 15:20:00 来源: 昕竹轩网站设计-【返回】
当我们使用 xampp 服务器的时候 xampp在运行的时候 数据库密码默认是空密码的..那么我们应该
怎样才能为 xampp 的mysql 设置一个密码呢?
现在我们来底下说明:
1、首页我们需要运行服务器然后,打开底下路径 并使用 dos 运行 mysqladmin 命令
xampp\mysql\bin\mysqladmin -u root password secret
其中,secret 为密码。
2、修改phpmyadmin密码。
但在phpmyadmin连接MySQL的时候出现了问题。提示如下:
MySQL 返回:文档
#1045 - Access denied for user 'pma'@'localhost' (using password: NO)
折腾了半天,,终于找到了解决的方法,打开\xampp\phpMyAdmin目录下的config.inc.php,修改部分参数,设置如下:
$cfg['Servers'][$i]['host'] = 'localhost'; // MySQL hostname or IP address
$cfg['Servers'][$i]['controluser'] ='root'; // MySQL control user settings
$cfg['Servers'][$i]['controlpass'] = 'password'; // password的为MySQL的root登陆密码
$cfg['Servers'][$i]['user'] = 'root'; // MySQL user
$cfg['Servers'][$i]['password'] ='password'; // MySQL password (only needed
$cfg['blowfish_secret'] ='abc'; //abc为任意字符

Copyright © 2014-2015 Htmcss.Com All Rights Reserved 版权所有昕竹轩网站设计 备案号:闽ICP备16024510号-4
你设置的联系邮箱是*: (当有人给你留言回复之时,联系邮箱可以及时通知你)
我们建议你填写正确的邮箱地址,如果你之前填写邮箱地址是错误的可以通过 【修改资料】 来重新设置