欧美一区二区三区老妇人-欧美做爰猛烈大尺度电-99久久夜色精品国产亚洲a-亚洲福利视频一区二区

02-influxdb的權(quán)限管理

  • 01-InfluxDB介紹請?zhí)砑渔溄用枋?/p>

    創(chuàng)新互聯(lián)是由多位在大型網(wǎng)絡(luò)公司、廣告設(shè)計公司的優(yōu)秀設(shè)計人員和策劃人員組成的一個具有豐富經(jīng)驗的團(tuán)隊,其中包括網(wǎng)站策劃、網(wǎng)頁美工、網(wǎng)站程序員、網(wǎng)頁設(shè)計師、平面廣告設(shè)計師、網(wǎng)絡(luò)營銷人員及形象策劃。承接:成都做網(wǎng)站、網(wǎng)站設(shè)計、外貿(mào)營銷網(wǎng)站建設(shè)、網(wǎng)站改版、網(wǎng)頁設(shè)計制作、網(wǎng)站建設(shè)與維護(hù)、網(wǎng)絡(luò)推廣、數(shù)據(jù)庫開發(fā),以高性價比制作企業(yè)網(wǎng)站、行業(yè)門戶平臺等全方位的服務(wù)。

  • 02-influxdb的權(quán)限管理

  • 03-Influxdb的備份與恢復(fù)

介紹

其實influxdb的權(quán)限語法和MySQL基本相似,看完以后你基本就能了解;

授權(quán)語法

  1. 創(chuàng)建用戶:CREATE USER <username> WITH PASSWORD '<password>'
  2. 授權(quán)權(quán)限:GRANT [READ,WRITE,ALL] ON <database_name> TO <username>
  3. 創(chuàng)建并授權(quán):CREATE USER <username> WITH PASSWORD '<password>' WITH ALL PRIVILEGES
  4. 取消授權(quán):REVOKE ALL PRIVILEGES FROM <username>
  5. 修改密碼:SET PASSWORD FOR <username> = '<password>'
  6. 刪除用戶:DROP USER <username>

開啟登錄認(rèn)證
vim /etc/influxdb/influxdb.conf

[http]
auth-enabled = true

[root@localhost tmp]# influx

Connected to http://localhost:8086 version 1.7.1
InfluxDB shell version: 1.7.1
Enter an InfluxQL query
> show databases
ERR: unable to parse authentication credentials
Warning: It is possible this error is due to not setting a database.
Please set a database with the command "use <database>".
> auth
username: monitor
password:
> show databases
name: databases
name
----
_internal
zabbix
telegraf
chronograf
> quit

授權(quán)操作

1.創(chuàng)建超級用戶
創(chuàng)建用戶:monitor
密碼:zabbix
權(quán)限:全部權(quán)限(超級用戶)
create user monitor with password 'zabbix' with all privileges

2.創(chuàng)建只讀用戶
用戶:monitor_ro
數(shù)據(jù)庫:monitordb
權(quán)限:指定數(shù)據(jù)庫的只讀權(quán)限

create user monitor_ro with password 'zabbix_apipwd'
grant read on monitordb to monitor_ro

3.創(chuàng)建可以寫用戶
用戶:monitor_rw
數(shù)據(jù)庫:monitordb
權(quán)限:指定數(shù)據(jù)庫的寫權(quán)限

create user monitor_rw with password 'zabbix_apipwd'
grant write on monitordb to monitor_rw

4.取消用戶授權(quán)
取消用戶授權(quán):

REVOKE ALL PRIVILEGES FROM monitor_rw

5.查看所有用戶

SHOW USERS
user admin


monitor true
monitor_ro false
monitor_rw false

6.刪除用戶

DROP USER monitor_rw

本文名稱:02-influxdb的權(quán)限管理
轉(zhuǎn)載源于:http://www.chinadenli.net/article14/ieoide.html

成都網(wǎng)站建設(shè)公司_創(chuàng)新互聯(lián),為您提供靜態(tài)網(wǎng)站關(guān)鍵詞優(yōu)化外貿(mào)網(wǎng)站建設(shè)網(wǎng)站營銷網(wǎng)站維護(hù)網(wǎng)站制作

廣告

聲明:本網(wǎng)站發(fā)布的內(nèi)容(圖片、視頻和文字)以用戶投稿、用戶轉(zhuǎn)載內(nèi)容為主,如果涉及侵權(quán)請盡快告知,我們將會在第一時間刪除。文章觀點(diǎn)不代表本網(wǎng)站立場,如需處理請聯(lián)系客服。電話:028-86922220;郵箱:631063699@qq.com。內(nèi)容未經(jīng)允許不得轉(zhuǎn)載,或轉(zhuǎn)載時需注明來源: 創(chuàng)新互聯(lián)

微信小程序開發(fā)