1.查看用户
select user,host from mysql.user;
2、创建用户和数据库
mysql> create database tornado_test_002;
Query OK, 1 row affected (0.09 sec)
创建用户 设置密码
mysql> create user 'ubuntu'@'%' identified by 'ubuntu';
Query OK, 0 rows affected (0.02 sec)
数据库权限 赋给 用户
mysql> grant all on tornado_test_002.* to 'ubuntu'@'%';
Query OK, 0 rows affected (0.03 sec)