-- 设置密码
SHOW VARIABLES LIKE 'validate_password%';
set global validate_password_check_user_name = 'ON';
set global validate_password_policy = 'LOW';
set global validate_password_length = 6;
-- 创建数据库
create database if not exists smartbi;
-- 创建用户
create user [email protected] identified by "smartbi";
-- set password for [email protected] = password("smartbi");
grant all on smartbi.* to [email protected];
-- 授予用户远程登录权限
GRANT ALL PRIVILEGES ON *.* TO 'smartbi'@'%' IDENTIFIED BY 'smartbi' WITH GRANT OPTION;
-- 刷新权限
flush privileges;
标签:set,--,创建,数据库,mysql,smartbi,validate,password From: https://www.cnblogs.com/hjj1215/p/17998672