赞
踩
屏蔽:bind-address = 127.0.0.1
mysql -uroot -p root
mysql->use mysql
mysql->update user set host = '%' where user ='root';
mysql->grant all privileges on *.* to 'root'@'%' with grant option;
mysql->flush privileges;
mysql->exit;
sudo /etc/init.d/mysql restart
安装
卸载删除配置
免密码登录设置(刚安装可能直接可以登录)
修改 Mariadb root 密码
use mysql;
ALTER USER root@localhost IDENTIFIED VIA mysql_native_password; #作用不大
set password for 'root'@'localhost'=password('123456'); #修改密码
GRANT ALL PRIVILEGES ON *.* TO 'root'@'%'IDENTIFIED BY '123456' WITH GRANT OPTION; #被局域网访问
flush privileges;
把skip-grant-tablesi屏蔽掉,重启Mariadb
配置 Mariadb: 修改允许所有IP连接数据库
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。