influxdb的安装和使用
一:安装
$ wget https://dl.influxdata.com/influxdb/releases/influxdb-1.2.2.x86_64.rpm (下载包)
$ yum localinstall influxdb-1.2.2.x86_64.rpm (用yum进行本地安装)
$ vim /etc/influxdb/influxdb.conf (修改配置文件)
reporting-disabled = true ( 这个要设置真,关闭定时上传数据到influxdata.com)
#bind-address = ":8086"(这个需要自己手动添加,指定http的连接操作端口,默认为8086)
[admin]
# Determines whether the admin serviwherece is enabled.
enabled = true (web管理界面,1.1版本以上默认关闭。需要的话,可以手动打开)
# The default bind address used by the admin service.
bind-address = ":8083" (web服务界面的端口)
二、使用Influxdb
进入到influxdb中需要进入到该路径下:
InfluxDB中没有显式的新建表的语句,只能通过insert数据的方式来建立新表。
insert disk_free,hostname=server01 value=442221834240i
退出influxdb的命令是quit