docs: description of user privileges
This commit is contained in:
parent
ba0082da42
commit
9c2e0284fd
|
@ -61,7 +61,7 @@ The parameters are explained as follows.
|
|||
- pass: Modify the user's password.
|
||||
- enable: Whether to enable the user. 1 means to enable this user, 0 means to disable this user.
|
||||
- sysinfo: Whether the user can view system information. 1 means they can view system information, 0 means they cannot.
|
||||
- createdb: Whether to allow the user to create databases, 1 means allow, 0 means prohibit. // Supported starting from TDengine Enterprise version 3.3.2.0
|
||||
- createdb: Whether the user can create databases. 1 means they can create databases, 0 means they cannot. // Supported starting from TDengine Enterprise version 3.3.2.0
|
||||
|
||||
The following SQL disables the user test.
|
||||
|
||||
|
|
|
@ -19,8 +19,6 @@ The password can be up to 31 bytes long. The password can include letters, numbe
|
|||
|
||||
`CREATEDB` indicates whether the user can create databases. `1` means they can create databases, `0` means they have no permission to create databases. The default value is `0`. // Supported starting from TDengine Enterprise version 3.3.2.0
|
||||
|
||||
|
||||
|
||||
In the example below, we create a user with the password `123456` who can view system information.
|
||||
|
||||
```sql
|
||||
|
|
|
@ -12,7 +12,7 @@ TDengine 默认仅配置了一个 root 用户,该用户拥有最高权限。TD
|
|||
|
||||
创建用户的操作只能由 root 用户进行,语法如下。
|
||||
```sql
|
||||
create user user_name pass'password' [sysinfo {1|0}] {createdb {1|0}}
|
||||
create user user_name pass'password' [sysinfo {1|0}] [createdb {1|0}]
|
||||
```
|
||||
|
||||
相关参数说明如下。
|
||||
|
@ -56,7 +56,7 @@ alter_user_clause: {
|
|||
- pass:修改用户密码。
|
||||
- enable:是否启用用户。1 表示启用此用户,0 表示禁用此用户。
|
||||
- sysinfo :用户是否可查看系统信息。1 表示可以查看系统信息,0 表示不可以查看系统信息
|
||||
- createdb: 用户是否可创建数据库。1 表示可以创建数据库,0 表示不可以创建数据库。// 从 TDengine 企业版 3.3.2.0 开始支持
|
||||
- createdb:用户是否可创建数据库。1 表示可以创建数据库,0 表示不可以创建数据库。// 从 TDengine 企业版 3.3.2.0 开始支持
|
||||
|
||||
如下 SQL 禁用 test 用户。
|
||||
```sql
|
||||
|
|
|
@ -17,7 +17,7 @@ CREATE USER user_name PASS 'password' [SYSINFO {1|0}] [CREATEDB {1|0}];
|
|||
密码最长不超过 31 个字节。密码可以包含字母、数字以及除单引号、双引号、反引号、反斜杠和空格以外的特殊字符,密码不能为空字符串。
|
||||
|
||||
`SYSINFO` 表示该用户是否能够查看系统信息。`1` 表示可以查看,`0` 表示无权查看。系统信息包括服务配置、dnode、vnode、存储等信息。缺省值为 `1`。
|
||||
`CREATEDB` 表示该用户是否可以创建数据库。`1` 表示可以,`0` 表示不可以。缺省值为 `0`。// 从 TDengine 企业版 3.3.2.0 开始支持
|
||||
`CREATEDB` 表示该用户是否能够创建数据库。`1` 表示可以创建,`0` 表示无权创建。缺省值为 `0`。// 从 TDengine 企业版 3.3.2.0 开始支持
|
||||
|
||||
在下面的示例中,我们创建一个密码为 `123456` 且可以查看系统信息的用户。
|
||||
|
||||
|
|
Loading…
Reference in New Issue