All articles| All Pictures| All Softwares| All Video| Go home page| Write articles| Upload pictures

Reading number is top 10 articles
VS,2008和.NET,3.5,Beta2新特性介绍_[Asp.Net教程]
Visual C++ 6.0教程:函数重载概述
ASP.NET定制错误处理页面_[Asp.Net教程]
利用XMLHTTP无刷新自动实时更新数据_[XML教程]
C#教程:注册COM+服务组件应用实例
加密和解密ASP.NET配置文件(Web.config)_[Asp.Net教程]
动态生成DataTable代码_[Asp.Net教程]
浅淡PHP生成HTML的思路_[PHP教程]
.NET开发不可不知、不可不用的辅助类(一)_[Asp.Net教程]
XML入门教程-XML CDATA_[XML教程]
Reading number is top 10 pictures
Li Zongrui hunting video screenshots2
mythology hero1
NeedWallpaper11
两张抽象画
NeedWallpaper8
六种更聪明的工作方法
美女
浴室里的美女
The world first motorcycle will be auctioned for 21000 pounds
张家界的玻璃桥
Download software ranking
Dance with duck(male prostitution)
dreamweaver8中文版
Unix video tutorial14
Macromedia Dreamweaver 8
虚拟机汉化软件
Boxer's Top ten classic battle4
C#程序员参考手册
网络管理员第三版
Professional killers2 for Android
Take off clothes to survival
归海一刀 published in(发表于) 2014/2/10 6:46:10 Edit(编辑)
PHP5连接Mysql5的认证协议问题_[PHP教程]

PHP5连接Mysql5的认证协议问题_[PHP教程]

PHP5连接Mysql5的认证协议问题_[PHP教程]

MYSQL 4.1以后, 采用了一种新的用户认证协议, 对于老的客户端会出现不支持认证协议的错误, 以下是官方网站的解决方法﹔

1Upgrade all client programs to use a 4.1.1 or newer client library.

更新客户端库,这需要更新PHP的扩展库,对于老的api PHP已经不提供了这样的扩展库了

2When connecting to the server with a pre-4.1 client program, use an account that still has a pre-4.1-style password.

使用以前建立的账号连接,对于在新的认证协议下建立的账户就不行了

3Reset the password to pre-4.1 style for each user that needs to use a pre-4.1 client program. This can be done using the SET PASSWORD statement and the OLD_PASSWORD() function: mysql> SET PASSWORD FOR

-> 'some_user'@'some_host' = OLD_PASSWORD('newpwd');

Alternatively, use UPDATE and FLUSH PRIVILEGES: mysql> UPDATE mysql.user SET Password = OLD_PASSWORD('newpwd') -> WHERE Host = 'some_host' AND User = 'some_user';

mysql> FLUSH PRIVILEGES;

Substitute the password you want to use for ``newpwd'' in the preceding examples. MySQL cannot tell you what the original password was, so you'll need to pick a new one.

这是一个不错的办法,新建立的账号采用老式的加密协议

4Tell the server to use the older password hashing algorithm:

Start mysqld with the --old-passwords option.

这样新认证协议的优点就没法使用了

5Assign an old-format password to each account that has had its password updated to the longer 4.1 format. You can identify these accounts with the following query: mysql> SELECT Host, User, Password FROM mysql.user

-> WHERE LENGTH(Password) > 16;

For each account record displayed by the query, use the Host and User values and assign a password using the OLD_PASSWORD() function and either SET PASSWORD or UPDATE, as described earlier.

恢复已经升级了口令到老样式。





添加到del.icio.us 添加到新浪ViVi 添加到百度搜藏 添加到POCO网摘 添加到天天网摘365Key 添加到和讯网摘 添加到天极网摘 添加到黑米书签 添加到QQ书签 添加到雅虎收藏 添加到奇客发现 diigo it 添加到饭否 添加到飞豆订阅 添加到抓虾收藏 添加到鲜果订阅 digg it 貼到funP 添加到有道阅读 Live Favorites 添加到Newsvine 打印本页 用Email发送本页 在Facebook上分享


Disclaimer Privacy Policy About us Site Map

If you have any requirements, please contact webmaster。(如果有什么要求,请联系站长)
Copyright ©2011-
uuhomepage.com, Inc. All rights reserved.