InfluxDB学习(三):InfluxDB数据库series、points、shard概念
一. Series
InfluxDB中的series是一种集合的概念,在同一个database中,相同retention policy、相同measurement、相同tag的数据属于一个series集合,同一个series的数据在物理上按照时间顺序排列在一起。
将以下数据插入到InfluxDB中。
insert instance,dc=us-west-2,server=ec2-dcas-address-db-01 cpu_usage_user=5.2,cpu_usage_system=1.0,cpu_usage_idle=90.7,cpu_usage_wait=3.1 insert instance,dc=us-west-2,server=ec2-dcas-address-db-01 memory_total=8009556,memory_used=1417488,memory_free=244076,memory_shared=118960,memory_buffered=0,memory_cached=6347992,memory_available=6082012 insert instance,dc=us-west-2,server=ec2-dcsindexsvc-01 cpu_usage_user=4.1,cpu_usage_system=2.0,cpu_usage_idle=97.7,cpu_usage_wait=2.3 insert instance,dc=us-west-2,server=ec2-dcsindexsvc-01 memory_total=32394732,memory_used=11330204,memory_free=5618464,memory_shared=229908,memory_buffered=0,memory_cached=15446064,memory_available=20433240 insert instance,dc=us-west-2,server=ec2-autodenalicontentpoi-01 cpu_usage_user=13.6,cpu_usage_system=0.8,cpu_usage_idle=85.6,cpu_usage_wait=0.6 insert instance,dc=us-west-2,server=ec2-autodenalicontentpoi-01 memory_total=64990084,memory_used=842448,memory_free=348420,memory_shared=17174872,memory_buffered=0,memory_cached=63799216,memory_available=46397536
注意:
- 插入的数据中measurement为instance,tag为dc和server,field为cpu***和memory***.
- 上述数据中,虽然插入了6条数据,但是每两条数据的tag都是重复的,根据Series集合的定义,在插入的6条数据中,属于3个series。
查看当前数据库的Series信息
> show series; key --- instance,dc=us-west-2,server=ec2-autodenalicontentpoi-01 instance,dc=us-west-2,server=ec2-dcas-address-db-01 instance,dc=us-west-2,server=ec2-dcsindexsvc-01
Series中的key为measurement,tag_key1=tag_value1,tag_key2=tag_value2..., value即为field_key1=field_value1,field_key2=field_value2...
相关推荐
AnotherSpace 2020-11-03
Claroja 2020-10-16
wpfeitian 2020-10-05
伏雌摘星阁 2020-07-29
jackadmi 2020-06-24
QiHsMing 2020-06-08
SoarFly00 2020-06-03
拿什么来拯救自己 2020-05-28
zhangwentaohh 2020-05-21
zhangskd 2020-05-10
JakobHu 2020-05-09
manimnchn 2020-05-01
andylanzhiyong 2020-04-30
yishujixiaoxiao 2020-04-20
fenxinzi 2020-04-14
sgafdsg 2020-04-11
abdstime 2020-04-10
bluecarrot 2020-04-08