简体   繁体   English

共享石墨集群中两个节点的缓存中的指标

[英]Sharing the metrics in cache of two nodes within a graphite cluster

I have a graphite cluster with 2 nodes under and ELB. 我有一个石墨簇,在ELB下有2个节点。 Both of them share a same NFS to store the metrics.I didn't have a problem in accessing the metrics that are already written to the NFS.The problem arises in the case where node 1 have some metrics in its cache and have not written yet to the NFS and node 2 tries to access that metric.So one solution that I have in mind is to include the IP of both servers in local_setting.py 两者共享同一个NFS来存储指标。访问已写入NFS的指标没有问题,这是在节点1的缓存中有一些指标但尚未写入的情况下出现的到NFS,节点2尝试访问该指标。因此,我想到的一个解决方案是将两个服务器的IP都包含在local_setting.py中

#########################
# Cluster Configuration #
#########################
#CLUSTER_SERVERS = ["10.x.x.1:80", "10.x.x.2:80"]

Is there any other way or a better solution to access the cache in node 1 from node 2 under the same ELB ? 是否有其他方法或更好的解决方案可以从同一ELB下的节点2访问节点1中的缓存?

Graphite is using files on the disk for resolving globs (eg '*') in metric names. Graphite正在使用磁盘上的文件来解析度量标准名称中的glob(例如“ *”)。 If the metric is not yet written to disk - it will not be visible in Graphite. 如果该指标尚未写入磁盘-在Graphite中将不可见。 Adding CLUSTER_SERVERS will not help because they should be another graphite-web instances and not caches. 添加CLUSTER_SERVERS将无济于事,因为它们应该是另一个graphite-web实例,而不是缓存。 You can add both caches to CARBONLINK_HOSTS , ie 您可以将两个缓存都添加到CARBONLINK_HOSTS ,即

CARBONLINK_HOSTS = ['10.xx1:7002','10.xx2:7002']

but I doubt that helps because of what I said above. 但由于上面我所说的,我怀疑这是否有帮助。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM