w1100n
This site is best viewed in Google Chrome
7/13/2017 16:21

influxdb current version 1.3.1

#install
#archlinux
yaourt -S influxdb

#redhat/centos
sudo yum localinstall influxdb-1.2.4.x86_64.rpm

#for Linux Binaries (64-bit)
tar xvfz influxdb-1.3.1_linux_amd64.tar.gz
rsync -r /path/to/influxdb-1.2.4-1/ /

#edit config file
emacs /etc/influxdb/influxdb.conf

#reporting-disabled = false

[meta]
dir = “/var/lib/influxdb/meta”
#retention-autocreate = true

[data]
dir = “/var/lib/influxdb/data”
wal-dir = “/var/lib/influxdb/wal”
wal-fsync-delay = “0s”

index-version = “inmem”

index-version = “tsi1”

trace-logging-enabled = false
query-log-enabled = true
cache-max-memory-size = 1073741824
cache-snapshot-memory-size = 26214400

超过10分钟没有写入, 把cache写到新的TSM文件

cache-snapshot-write-cold-duration = “10m”

[coordinator]
#慢查询
log-queries-after = “10s”

[retention]

#edit file /etc/default/influxdb
STDERR=/data/logs/influxdb/influxdb.log

#edit logrotate config, modify log path
/etc/logrotate.d/influxdb

# chown
chown influxdb:influxdb /data/influxdb/
chown influxdb:influxdb /data/logs/influxdb/

#start
service influxdb start
#or
sudo influxd

#connect via cli, rfc3339:日期格式YYYY-MM-DDTHH:MM:SS.nnnnnnnnnZ
influx -precision rfc3339

#create db
create database db0

#show db
dhow databases

#use
use db0

drop series from series_name

Comments are closed.

<< Previous Posts Newer Posts >>
辽ICP备14012896