influxdb

cat <<EOF | sudo tee /etc/yum.repos.d/influxdb.repo
[influxdb]
name = InfluxDB Repository - RHEL \$releasever
baseurl = https://repos.influxdata.com/rhel/\$releasever/\$basearch/stable
enabled = 1
gpgcheck = 1
gpgkey = https://repos.influxdata.com/influxdb.key
EOF
yum -y install influxdb
service influxdb start

启动后TCP端口:8083 为InfluxDB 管理控制台
  TCP端口:8086 为客户端和InfluxDB通信时的HTTP API
启动后InfluxDB用户认证默认是关闭的,先创建用户:geekwolf geekwolf
命令行输入influx

基本使用

create database collectdb
show databases
show users
create user ops with password '123123'
grant all privileges on collectdb to ops

CREATE USER test WITH PASSWORD 'password' WITH ALL PRIVILEGES
CREATE USER "admin" WITH PASSWORD 'verysecret' WITH ALL PRIVILEGES

开启验证

修改配置文件启用认证
sed -i ’s#auth-enabled = false#auth-enabled = true#g’ /etc/influxdb/influxdb.conf
service influxdb restart

influxdb开启对collectd的支持

[[collectd]]
enabled = true
bind-address = "0.0.0.0:25826"
database = "collectdb"
typesdb = "/opt/collectd/share/collectd/types.db"
batch-size = 5000
batch-pending = 10
batch-timeout = "10s"
read-buffer = 0in
Copyright © opschina.org 2017 with zzlyzq@gmail.com all right reserved,powered by Gitbook该文件修订时间: 2017-07-11 11:32:48

results matching ""

    No results matching ""