标签:style blog http os sp 数据 2014 log bs
InfluxDB 的用户有三种:
具有下面权限:
默认它有一个用户名是 root, 密码也是 root的 账户
集群管理员的操作命令如下:
# get list of cluster admins curl
curl ‘http://localhost:8086/cluster_admins?u=root&p=root‘
# add cluster admin
curl -X POST ‘http://localhost:8086/cluster_admins?u=root&p=root‘ \
-d ‘{"name": "paul", "password": "i write teh docz"}‘
# update cluster admin password
curl -X POST ‘http://localhost:8086/cluster_admins/paul?u=root&p=root‘ \
-d ‘{"password": "new pass"}‘
# delete cluster admin
curl -X DELETE ‘http://localhost:8086/cluster_admins/paul?u=root&p=root‘
对应的界面管理功能如下:
database admin 可以对当前数据库增加或者删除database admin 和 database user。
对不同的库则是没有权限的。
database user能够对当前库进行读写操作。不能对数据库用户进行调整,
对应的操作如下:
# Database users, with a database name of site_dev # add database user curl -X POST ‘http://localhost:8086/db/site_dev/users?u=root&p=root‘ -d ‘{"name": "paul", "password": "i write teh docz"}‘ # delete database user curl -X DELETE ‘http://localhost:8086/db/site_dev/users/paul?u=root&p=root‘ # update user‘s password curl -X POST ‘http://localhost:8086/db/site_dev/users/paul?u=root&p=root‘ -d ‘{"password": "new pass"}‘ # get list of database users curl ‘http://localhost:8086/db/site_dev/users?u=root&p=root‘ # add database admin privilege curl -X POST ‘http://localhost:8086/db/site_dev/users/paul?u=root&p=root‘ -d ‘{"admin": true}‘ # remove database admin privilege curl -X POST ‘http://localhost:8086/db/site_dev/users/paul?u=root&p=root‘ -d ‘{"admin": false}‘
标签:style blog http os sp 数据 2014 log bs
原文地址:http://www.cnblogs.com/ghj1976/p/4110605.html