开发者社区> 问答> 正文

数据库密码正确但是网站提示数据库连不上

已解决

展开
收起
2018-01-24 23:21:04 1260 0
1 条回答
写回答
取消 提交回答
  • 采纳回答

    详细解答可以参考官方帮助文档


    mysqlnd cannot connect to MySQL 4.1+ using the old insecure authentication. Please use an administration tool to reset your password with the command SET PASSWORD = PASSWORD(‘your_existing_password’). This will store a new, and more secure, hash value in mysql.user. If this user is used in other scripts executed by PHP 5.2 or earlier you might need to remove the old-passwords flag from your my.cnf file

     

    这个问题的意思是在本地上进行测试的环境mysql为4.1版本,更换服务器为5.1版本,需要更换php版本和更换mysql的数据加密方式来进行解决。

     

    登陆主机管理平台 高级环境设置>修改php版本

    2015-11-11(01).JPG

     

    在数据库信息中重置数据库密码,修改数据的加密方式,如下图所示。

    2015-11-11(02).JPG

     

     

    如问题还未解决,请联系售后技术支持

    2018-01-28 07:26:52
    赞同 展开评论 打赏
问答排行榜
最热
最新

相关电子书

更多
2022 DTCC-阿里云一站式数据库上云最佳实践 立即下载
云时代的数据库技术趋势 立即下载
超大型金融机构国产数据库全面迁移成功实践 立即下载