Home  >  Article  >  Database  >  MySql 安装时的1045错误

MySql 安装时的1045错误

WBOY
WBOYOriginal
2016-06-07 17:58:401066browse

MySql安装到最后一步的时候,出现1045的错误有两种解决办法。

解决办法1. 卸载重装,不设root密码,因为MySql默认密码为空。

解决办法2. 保持现在的密码,打开“MySQL Command Line Client”输入你的密码(安装时设的那个,如果密码不对可以试下空密码登录,有可能安装时密码设置无效)。登录成功后输入命令:
SET PASSWORD FOR 'root'@'localhost' = PASSWORD('mysql'); 'mysql'是新设置的密码。修改密码成功后再配置Mysql就OK了。

附:Mysql关闭出错蜂鸣的办法,打开MySql安装目录下的 my.ini 文件,在[mysql]行下添加这个语句'no-beep', 保存,重启Mysql服务就OK了。

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn