首先,mysql8与mysql5.7不一样,centos上安装好最新版本的mysql8后,在etc下会生成配置文件my.cnf,但是按照度娘的方法是不起作用的,在my.cnf里做任何修改都没用,甚至会使mysql无法启动,mysql8的配置在etc/my.cnf.d这个文件夹里, mysql-default-authentication-plugin.cnf这个文件是配置文件:
添加用户的方式也不一样了,mysql8要分开,先添加账号,再赋权:
create user test@localhost identified by '123456';
账号添加后,赋予这个账号对应的权限:
grant all privileges on test_database.* to test@% with grant option;
然后刷新权限:
flush privileges;
查看权限:
show grants for test@localhost;
撤销权限:
revoke all privileges on test_database.* from test@localhost;
Mysql8新增用户,mysql8配置权限,mysql8配置,mysql8配置文件 Linux命令,scp,scp命令,Linux复制 git commit git add centos git 搭建FTP,Linux FTP,禁止FTP登录ssh 上传文件,阿里云OSS上传,文件上传到OSS,OSS文件上传,OSS上传 微信支付,微信支付V3,PHP微信支付,微信nativePay支付,微信jsapi支付 微信支付,微信支付V3,PHP微信支付 bootstrap4 modal, lavarel The subversion command line tools are no longer provided by Xcode. 银联支付,tp5.1银联支付 支付宝即时到账,PHP支付宝 system libzip must be upgraded to version >= 0.11 CMake 3.0.2 or higher is required Class 'ZipArchive' not found chr() expects parameter 1 to be int php7.4 tcpdf unexpected '='