1. installation

vi /etc/yum.repos.d/influxdb.repo
#
[influxdb]
name=influxdb
baseurl=https://repos.influxdata.com/centos/$releasever/$basearch/stable/
enabled=1
gpgcheck=0
yum -y install influxdb
systemctl enable --now influxdb

2. samples

influx -execute "create user root with password 'Passw0rd' with all privileges"
influx -username root -password Passw0rd -execute "show databases"
influx -username root -password Passw0rd -execute "create database cid"
influx -username root -password Passw0rd -database cid -execute "insert temp s1=$RANDOM,s2=$RANDOM,s3=$RANDOM,s4=$RANDOM"
influx -username root -password Passw0rd -database cid -execute "select * from temp"
influx -username root -password Passw0rd -database cid -execute "select * from temp order by desc limit 10"
influx -username root -password Passw0rd -database cid -precision rfc3339 -execute "select * from temp order by desc limit 10"
influx -username root -password Passw0rd -database cid -format=csv -precision rfc3339 -execute "select * from temp order by desc limit 10"

3. backup & restore

influxd backup -portable -database cid backup/
influx -username root -password Passw0rd -execute "drop database cid;"
influxd restore -portable backup/