Centos7.3+Influxdb1.2+Grafana4.2

一、概述

InfluxDB 是一個開源分佈式時序、事件和指標數據庫。使用 Go 語言編寫,無需外部依賴。其設計目標是實現分佈式和水平伸縮擴展。
它有三大特性:
1. Time Series (時間序列):你可以使用與時間有關的相關函數(如最大,最小,求和等)
2. Metrics(度量):你可以實時對大量數據進行計算
3. Eevents(事件):它支持任意的事件數據

特點:
schemaless(無結構),可以是任意數量的列
Scalable
min, max, sum, count, mean, median 一系列函數,方便統計
Native HTTP API, 內置http支持,使用http讀寫
Powerful Query Language 類似sql
Built-in Explorer 自帶管理工具

二、安裝及配置InfluxDB
1、配置YUM源
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
2、yum安裝
yum install influxdb -y

systemctl start influxdb

influx -host '127.0.0.1' -port '8086'
[root@zabbix-grafana ~]# influx -host '127.0.0.1' -port '8086'
Connected to http://127.0.0.1:8086 version 1.2.2
InfluxDB shell version: 1.2.2
> show databases;
name: databases
name
----
_internal
> create database grafana
> use grafana
> show databases;
name: databases
name
----
_internal
grafana
> create user "grafana" with password 'grafana' with all privileges
> 



發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章