> SHOW USERS
user admin
---- -----
admin true
readonly false
monitor_user false
>
1.
2.
3.
4.
5.
6.
7.
2.创建用户
CREATE USER "myusername" WITH PASSWORD 'mypassword' WITH ALL PRIVILEGES
1.
运行示例:
> CREATE USER "my_test" WITH PASSWORD 'my_password' WITH ALL PRIVILEGES
>
> SHOW USERS
user admin
---- -----
admin true
readonly false
monitor_user false
my_test true
>
1.
2.
3.
4.
5.
6.
7.
8.
9.
10.
3.修改用户密码
SET PASSWORD FOR "my_test" = 'newpassword'
1.
4.删除用户
DROP USER "my_test"
1.
5.增加和查看用户权限
> GRANT WRITE ON "chronograf" TO "monitor_user"
>
> SHOW GRANTS FOR monitor_user
database privilege
-------- ---------
chronograf WRITE
>