开发者

解决mysql数据库设置远程连接权限执行grant all privileges on *.* to 'root'@'%' identified by &apo

mysql数据库设置远程连接权限,执行grant all privileges on *.* to 'root&js#39;@'%' identified by '密码' with grant optio报错

解决mysql数据库设置远程连接权限执行grant all privileges on *.* to 'root'@'%' identified by &apo

ERROR1558 (HY000): Column count ofmysql.user is wrong. Expectephpd 43, found 42. Created with MySQL 50556, now running 50639. Please use mysql_upgrade to fix this error.

解决办法:

使用命令:mysql_upgrade -u[username] -p[password]就可以解决。

使用mysql_upgrade对数据库的数据表结构等升级时,数据库引擎MyISAM 会做检查、修复的动作,InnoDB 执行 mysql_upgrade 没有作用。

查找MySQL的安装目录找到mysql_upgrade :

  • whereismysql_upgrade
  • cd /usr/bin/
  • ./mysql_upgrade -uroot -p123 (123为密码)

解决mysql数据库设置远程连接权限执行grant all privileges on *.* to 'root'@'%' identified by &apo

然后进入到mysql再执行权限修改即可:grant all privileges on *.* to 'root'@'%' identified by 'root4XML004a' with grant option;

如:

解决mysql数据库设置远程连接权限执行grant all privileges on *.* to 'root'@'%' identified by &apo

mysql中远程连接权限语句grant all privileges on *.* to ‘root‘@‘%&l编程squo; identified by ‘123456‘ with grant optio报错

grant all privileges on *.* to ‘root‘@‘%‘ identified by ‘123456‘ with grant optio

原因: mysql的版本问题,这条语句适用于MySQL8.0之前

解决: mysql8.0及以上版本需要使用以下语句:

create user root@'%' identified by '123456';
grant all pr开发者_Hadoopivileges on *.* to root@'%' with grant option;

到此这篇关于解决mysql数据库设置远程连接权限执行grant all privileges on *.* to 'root'python@'%' identified by '密码' with grant optio报错的文章就介http://www.devze.com绍到这了,更多相关mysql远程连接权限内容请搜索我们以前的文章或继续浏览下面的相关文章希望大家以后多多支持我们!

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新数据库

数据库排行榜